@@ -27,7 +27,8 @@ |
||
27 | 27 | * |
28 | 28 | *@package app\models |
29 | 29 | */ |
30 | -class Settings extends \lithium\data\Model { |
|
30 | +class Settings extends \lithium\data\Model |
|
31 | +{ |
|
31 | 32 | |
32 | 33 | public $validates = []; |
33 | 34 |
@@ -21,17 +21,32 @@ |
||
21 | 21 | |
22 | 22 | use app\controllers\SettingsController; |
23 | 23 | |
24 | -class SettingsControllerTest extends \lithium\test\Unit { |
|
24 | +class SettingsControllerTest extends \lithium\test\Unit |
|
25 | +{ |
|
25 | 26 | |
26 | - public function setUp() {} |
|
27 | + public function setUp() |
|
28 | + { |
|
29 | +} |
|
27 | 30 | |
28 | - public function tearDown() {} |
|
31 | + public function tearDown() |
|
32 | + { |
|
33 | +} |
|
29 | 34 | |
30 | - public function testIndex() {} |
|
31 | - public function testView() {} |
|
32 | - public function testAdd() {} |
|
33 | - public function testEdit() {} |
|
34 | - public function testDelete() {} |
|
35 | + public function testIndex() |
|
36 | + { |
|
37 | +} |
|
38 | + public function testView() |
|
39 | + { |
|
40 | +} |
|
41 | + public function testAdd() |
|
42 | + { |
|
43 | +} |
|
44 | + public function testEdit() |
|
45 | + { |
|
46 | +} |
|
47 | + public function testDelete() |
|
48 | + { |
|
49 | +} |
|
35 | 50 | } |
36 | 51 | |
37 | 52 | ?> |
@@ -21,11 +21,16 @@ |
||
21 | 21 | |
22 | 22 | use app\models\Settings; |
23 | 23 | |
24 | -class SettingsTest extends \lithium\test\Unit { |
|
24 | +class SettingsTest extends \lithium\test\Unit |
|
25 | +{ |
|
25 | 26 | |
26 | - public function setUp() {} |
|
27 | + public function setUp() |
|
28 | + { |
|
29 | +} |
|
27 | 30 | |
28 | - public function tearDown() {} |
|
31 | + public function tearDown() |
|
32 | + { |
|
33 | +} |
|
29 | 34 | |
30 | 35 | |
31 | 36 | } |
@@ -182,7 +182,7 @@ |
||
182 | 182 | $this->setVideoNotFound(parent::PROCESS_TRAKT, $row['id']); |
183 | 183 | $this->titleCache[] = $release['cleanname']; |
184 | 184 | } |
185 | - } else{ |
|
185 | + } else { |
|
186 | 186 | //Processing failed, set the episode ID to the next processing group |
187 | 187 | $this->setVideoNotFound(parent::PROCESS_TRAKT, $row['id']); |
188 | 188 | $this->titleCache[] = $release['cleanname']; |
@@ -783,8 +783,7 @@ |
||
783 | 783 | 'release_id' => 0, |
784 | 784 | 'method' => '' |
785 | 785 | ] |
786 | - ) |
|
787 | - { |
|
786 | + ) { |
|
788 | 787 | echo |
789 | 788 | PHP_EOL . |
790 | 789 | ColorCLI::headerOver('New name: ') . ColorCLI::primaryOver($data['new_name']) . PHP_EOL . |
@@ -37,12 +37,11 @@ |
||
37 | 37 | $errcnt=0; |
38 | 38 | |
39 | 39 | echo "\n"; |
40 | -foreach ($res as $regexrow) |
|
41 | -{ |
|
42 | - foreach ($regs as $regex){ |
|
40 | +foreach ($res as $regexrow) { |
|
41 | + foreach ($regs as $regex) { |
|
43 | 42 | try { |
44 | 43 | $res=preg_match($regexrow["regex"], $regex); |
45 | - }catch(Exception $e){ |
|
44 | + } catch(Exception $e) { |
|
46 | 45 | $errcnt++; |
47 | 46 | $strerr=str_pad((int) $errcnt,2," ",STR_PAD_LEFT); |
48 | 47 | echo "$strerr. id=".$regexrow["id"]. |
@@ -26,14 +26,11 @@ |
||
26 | 26 | $page->meta_description = ""; |
27 | 27 | $page->smarty->registerPlugin('modifier', 'ss', 'stripslashes'); |
28 | 28 | |
29 | - if (isset($_GET['modal'])) |
|
30 | - { |
|
29 | + if (isset($_GET['modal'])) { |
|
31 | 30 | $page->content = $page->smarty->fetch('viewxxx.tpl'); |
32 | 31 | $page->smarty->assign('modal', true); |
33 | 32 | echo $page->content; |
34 | - } |
|
35 | - else |
|
36 | - { |
|
33 | + } else { |
|
37 | 34 | $page->content = $page->smarty->fetch('viewxxxfull.tpl'); |
38 | 35 | $page->render(); |
39 | 36 | } |
@@ -10,8 +10,7 @@ |
||
10 | 10 | // set the current action |
11 | 11 | $action = isset($_REQUEST['action']) ? $_REQUEST['action'] : 'view'; |
12 | 12 | |
13 | -switch($action) |
|
14 | -{ |
|
13 | +switch($action) { |
|
15 | 14 | case 'submit': |
16 | 15 | if (isset($_POST['groupfilter']) && !empty($_POST['groupfilter'])) { |
17 | 16 | $groups = new Groups; |
@@ -6,14 +6,14 @@ |
||
6 | 6 | |
7 | 7 | $page = new AdminPage(); |
8 | 8 | |
9 | -if (isset($_GET['id'])) |
|
10 | -{ |
|
9 | +if (isset($_GET['id'])) { |
|
11 | 10 | $forum = new Forum(); |
12 | 11 | $forum->deletePost($_GET['id']); |
13 | 12 | } |
14 | 13 | |
15 | -if (isset($_GET['from'])) |
|
14 | +if (isset($_GET['from'])) { |
|
16 | 15 | $referrer = $_GET['from']; |
17 | -else |
|
16 | +} else { |
|
18 | 17 | $referrer = $_SERVER['HTTP_REFERER']; |
18 | +} |
|
19 | 19 | header("Location: " . $referrer); |