@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | |
| 39 | 39 | if (!empty($modules)) { |
| 40 | 40 | foreach ($modules as $key => $value) { |
| 41 | - $file = MODULES_ROOT . '/' . $value->getName() . '/menu.php'; |
|
| 41 | + $file = MODULES_ROOT.'/'.$value->getName().'/menu.php'; |
|
| 42 | 42 | |
| 43 | 43 | if (is_file($file)) { |
| 44 | 44 | include $file; |
@@ -51,9 +51,9 @@ discard block |
||
| 51 | 51 | |
| 52 | 52 | public function flushCache($tableName = '') |
| 53 | 53 | { |
| 54 | - if (!empty($tableName)) $table = $this->prefix . $tableName; |
|
| 55 | - else $table = $this->prefix . '*'; |
|
| 54 | + if (!empty($tableName)) $table = $this->prefix.$tableName; |
|
| 55 | + else $table = $this->prefix.'*'; |
|
| 56 | 56 | |
| 57 | - array_map('unlink', glob(TEMP_ROOT . '/' . self::$config['engine'] . '/' . $table . '*')); |
|
| 57 | + array_map('unlink', glob(TEMP_ROOT.'/'.self::$config['engine'].'/'.$table.'*')); |
|
| 58 | 58 | } |
| 59 | 59 | } |
@@ -51,8 +51,11 @@ |
||
| 51 | 51 | |
| 52 | 52 | public function flushCache($tableName = '') |
| 53 | 53 | { |
| 54 | - if (!empty($tableName)) $table = $this->prefix . $tableName; |
|
| 55 | - else $table = $this->prefix . '*'; |
|
| 54 | + if (!empty($tableName)) { |
|
| 55 | + $table = $this->prefix . $tableName; |
|
| 56 | + } else { |
|
| 57 | + $table = $this->prefix . '*'; |
|
| 58 | + } |
|
| 56 | 59 | |
| 57 | 60 | array_map('unlink', glob(TEMP_ROOT . '/' . self::$config['engine'] . '/' . $table . '*')); |
| 58 | 61 | } |
@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | 'Podane hasła nie są identyczne!' |
| 23 | 23 | ) |
| 24 | 24 | ); |
| 25 | - $this->redirect(DIR . '/admin/users/add'); |
|
| 25 | + $this->redirect(DIR.'/admin/users/add'); |
|
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 | $addModel = new AddModel(); |
@@ -36,7 +36,7 @@ discard block |
||
| 36 | 36 | ) |
| 37 | 37 | ); |
| 38 | 38 | $addModel->flushCache('users'); |
| 39 | - $this->redirect(DIR . '/admin/users/edit/' . $id); |
|
| 39 | + $this->redirect(DIR.'/admin/users/edit/'.$id); |
|
| 40 | 40 | } |
| 41 | 41 | AlertsCollection::add( |
| 42 | 42 | new Alert( |
@@ -27,7 +27,7 @@ |
||
| 27 | 27 | if ($form->isValid()) { |
| 28 | 28 | $form->delete(); |
| 29 | 29 | $delModel->flushCache('albums'); |
| 30 | - $this->redirect(DIR . '/admin/albums'); |
|
| 30 | + $this->redirect(DIR.'/admin/albums'); |
|
| 31 | 31 | } |
| 32 | 32 | |
| 33 | 33 | $form->displayAlerts(); |
@@ -31,7 +31,7 @@ |
||
| 31 | 31 | |
| 32 | 32 | if ($form->isValid() and $form->update()) { |
| 33 | 33 | $editModel->flushCache('albums'); |
| 34 | - $this->redirect(DIR . '/admin/albums/edit/' . $id); |
|
| 34 | + $this->redirect(DIR.'/admin/albums/edit/'.$id); |
|
| 35 | 35 | } |
| 36 | 36 | |
| 37 | 37 | $form->displayAlerts(); |
@@ -27,7 +27,7 @@ |
||
| 27 | 27 | if ($form->isValid()) { |
| 28 | 28 | $id = $form->save(); |
| 29 | 29 | $addModel->flushCache('albums'); |
| 30 | - $this->redirect(DIR . '/admin/albums/edit/' . $id); |
|
| 30 | + $this->redirect(DIR.'/admin/albums/edit/'.$id); |
|
| 31 | 31 | } |
| 32 | 32 | |
| 33 | 33 | $form->displayAlerts(); |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | if ($form->isValid()) { |
| 30 | 30 | $form->delete(); |
| 31 | 31 | $delModel->flushCache('categories'); |
| 32 | - $this->redirect(DIR . '/admin/albums/categories'); |
|
| 32 | + $this->redirect(DIR.'/admin/albums/categories'); |
|
| 33 | 33 | } |
| 34 | 34 | |
| 35 | 35 | $form->displayAlerts(); |
@@ -30,7 +30,7 @@ |
||
| 30 | 30 | |
| 31 | 31 | if ($form->isValid() and $form->update()) { |
| 32 | 32 | $editModel->flushCache('categories'); |
| 33 | - $this->redirect(DIR . '/admin/albums/categories/edit/' . $id); |
|
| 33 | + $this->redirect(DIR.'/admin/albums/categories/edit/'.$id); |
|
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | $form->displayAlerts(); |
@@ -26,7 +26,7 @@ |
||
| 26 | 26 | if ($form->isValid()) { |
| 27 | 27 | $id = $form->save(); |
| 28 | 28 | $addModel->flushCache('categories'); |
| 29 | - $this->redirect(DIR . '/admin/albums/categories/edit/' . $id); |
|
| 29 | + $this->redirect(DIR.'/admin/albums/categories/edit/'.$id); |
|
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | $form->displayAlerts(); |
@@ -25,7 +25,7 @@ |
||
| 25 | 25 | if ($form->isValid()) { |
| 26 | 26 | $form->delete(); |
| 27 | 27 | $delModel->flushCache('pages'); |
| 28 | - $this->redirect(DIR . '/admin/pages'); |
|
| 28 | + $this->redirect(DIR.'/admin/pages'); |
|
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | $form->displayAlerts(); |