Completed
Push — master ( 0ececb...02ac3e )
by Sergey
03:32
created
examples/features/highload_optimization.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 
3 3
 require_once(__DIR__ . '/../../src/PhpConsole/__autoload.php');
4 4
 
5
-if(PhpConsole\Connector::getInstance()->isActiveClient()) {
5
+if (PhpConsole\Connector::getInstance()->isActiveClient()) {
6 6
 	// ... any PHP Console initialization & configuration code
7 7
 }
8 8
 
Please login to merge, or discard this patch.
examples/features/handle_on_redirect.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,8 +8,8 @@
 block discarded – undo
8 8
 
9 9
 $redirectNum = isset($_GET['num']) ? $_GET['num'] + 1 : 1;
10 10
 
11
-if($redirectNum < 4) {
12
-	if($redirectNum == 2) {
11
+if ($redirectNum < 4) {
12
+	if ($redirectNum == 2) {
13 13
 		echo ${'oops' . $redirectNum};
14 14
 	}
15 15
 	$handler->debug('Debug message in redirect №' . $redirectNum);
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,8 +14,7 @@
 block discarded – undo
14 14
 	}
15 15
 	$handler->debug('Debug message in redirect №' . $redirectNum);
16 16
 	header('Location: ?num=' . $redirectNum);
17
-}
18
-else {
17
+} else {
19 18
 	$handler->debug('Debug message in current page');
20 19
 	echo '
21 20
 		There was 3 redirects before this page is displayed, and you can see all handled error & debug messages in collapsed blocks in JavaScript Console(Ctrl+Shift+J).
Please login to merge, or discard this patch.
examples/features/complex_usage_example.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,13 +3,13 @@  discard block
 block discarded – undo
3 3
 require_once(__DIR__ . '/../../src/PhpConsole/__autoload.php');
4 4
 
5 5
 $password = null;
6
-if(!$password) {
6
+if (!$password) {
7 7
 	die('Please set $password variable value in ' . __FILE__);
8 8
 }
9 9
 
10 10
 $connector = PhpConsole\Helper::register();
11 11
 
12
-if($connector->isActiveClient()) {
12
+if ($connector->isActiveClient()) {
13 13
 	// Init errors & exceptions handler
14 14
 	$handler = PC::getHandler();
15 15
 	$handler->start(); // start handling PHP errors & exceptions
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 	'longString' => '11111111112222222222333333333344444444445',
80 80
 	'someObject' => new DebugExample(),
81 81
 	'someCallback' => array(new DebugExample(), 'someMethod'),
82
-	'someClosure' => function () {
82
+	'someClosure' => function() {
83 83
 	},
84 84
 	'someResource' => fopen(__FILE__, 'r'),
85 85
 	'manyItemsArray' => array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11),
Please login to merge, or discard this patch.
Doc Comments   +7 added lines patch added patch discarded remove patch
@@ -14,10 +14,17 @@
 block discarded – undo
14 14
 		$this->method1(array(1, 2), new stdClass()); // this arguments will be displayed in error backtrace
15 15
 	}
16 16
 
17
+	/**
18
+	 * @param integer[] $a
19
+	 * @param stdClass $b
20
+	 */
17 21
 	protected function method1($a, $b) {
18 22
 		$this->method2('some long string argument');
19 23
 	}
20 24
 
25
+	/**
26
+	 * @param string $c
27
+	 */
21 28
 	public function method2($c) {
22 29
 		echo $undefinedVar; // E_NOTICE error
23 30
 		file_get_contents('not_existed.file'); // E_WARNING error
Please login to merge, or discard this patch.
examples/features/protect_by_password.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
 require_once(__DIR__ . '/../../src/PhpConsole/__autoload.php');
4 4
 
5 5
 $password = null;
6
-if(!$password) {
6
+if (!$password) {
7 7
 	die('Please set $password variable value in ' . __FILE__);
8 8
 }
9 9
 
Please login to merge, or discard this patch.
examples/features/debug_vars.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
 	'longString' => '11111111112222222222333333333344444444445',
46 46
 	'someObject' => new DebugExample(),
47 47
 	'someCallback' => array(new DebugExample(), 'someMethod'),
48
-	'someClosure' => function () {
48
+	'someClosure' => function() {
49 49
 	},
50 50
 	'someResource' => fopen(__FILE__, 'r'),
51 51
 	'manyItemsArray' => array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11),
Please login to merge, or discard this patch.
examples/utils/detect_headers_limit.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
  * @author Barbushin Sergey http://linkedin.com/in/barbushin
7 7
  */
8 8
 
9
-if(isset($_GET['size'])) {
9
+if (isset($_GET['size'])) {
10 10
 	header('X: ' . str_repeat('x', $_GET['size']));
11 11
 	die('ok');
12 12
 }
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 	$testDiff = floor($isOk ? $testDiff * 2 : $testDiff / 2);
26 26
 	$size += $testDiff * ($isOk ? 1 : -1);
27 27
 }
28
-while($testDiff && !($size > $testLimit && $isOk));
28
+while ($testDiff && !($size > $testLimit && $isOk));
29 29
 
30 30
 ?>
31 31
 
Please login to merge, or discard this patch.
examples/index.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 );
35 35
 
36 36
 // Highlight & print feature script source code
37
-if(isset($_GET['highlight']) && isset($features[$_GET['highlight']])) {
37
+if (isset($_GET['highlight']) && isset($features[$_GET['highlight']])) {
38 38
 	highlight_string(preg_replace('/(\$password\s*=\s*).*?;/', '\1*****;', file_get_contents(__DIR__ . '/features/' . $_GET['highlight'] . '.php')));
39 39
 	exit;
40 40
 }
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
 
110 110
 <h1 align="center">PHP Console Features examples & Utils</h1>
111 111
 
112
-<?php if(!$isActiveClient) { ?>
112
+<?php if (!$isActiveClient) { ?>
113 113
 	<span class="warning" align="center">
114 114
 	Google Chrome extension
115 115
 	<a href="https://chrome.google.com/webstore/detail/php-console/nfhmhhlpfleoednkpnnnkolmclajemef" target="_blank">PHP Console</a>
Please login to merge, or discard this patch.
examples/features/eval_terminal.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
 require_once(__DIR__ . '/../../src/PhpConsole/__autoload.php');
4 4
 
5 5
 $password = null;
6
-if(!$password) {
6
+if (!$password) {
7 7
 	die('Please set $password variable value in ' . __FILE__);
8 8
 }
9 9
 
Please login to merge, or discard this patch.