@@ -59,7 +59,7 @@ |
||
59 | 59 | return; |
60 | 60 | } |
61 | 61 | |
62 | - $class = 'HTMLPurifier_URIScheme_' . $scheme; |
|
62 | + $class = 'HTMLPurifier_URIScheme_'.$scheme; |
|
63 | 63 | if (!class_exists($class)) { |
64 | 64 | return; |
65 | 65 | } |
@@ -2,7 +2,7 @@ discard block |
||
2 | 2 | |
3 | 3 | // constants are slow, so we use as few as possible |
4 | 4 | if (!defined('HTMLPURIFIER_PREFIX')) { |
5 | - define('HTMLPURIFIER_PREFIX', realpath(dirname(__FILE__) . '/..')); |
|
5 | + define('HTMLPURIFIER_PREFIX', realpath(dirname(__FILE__).'/..')); |
|
6 | 6 | } |
7 | 7 | |
8 | 8 | // accomodations for versions earlier than 5.0.2 |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | // Zend extensions such as Zend debugger and APC, this invariant |
47 | 47 | // may be broken. Since we have efficient alternatives, pay |
48 | 48 | // the cost here and avoid the bug. |
49 | - require_once HTMLPURIFIER_PREFIX . '/' . $file; |
|
49 | + require_once HTMLPURIFIER_PREFIX.'/'.$file; |
|
50 | 50 | return true; |
51 | 51 | } |
52 | 52 | |
@@ -63,11 +63,11 @@ discard block |
||
63 | 63 | // Custom implementations |
64 | 64 | if (strncmp('HTMLPurifier_Language_', $class, 22) === 0) { |
65 | 65 | $code = str_replace('_', '-', substr($class, 22)); |
66 | - $file = 'HTMLPurifier/Language/classes/' . $code . '.php'; |
|
66 | + $file = 'HTMLPurifier/Language/classes/'.$code.'.php'; |
|
67 | 67 | } else { |
68 | - $file = str_replace('_', '/', $class) . '.php'; |
|
68 | + $file = str_replace('_', '/', $class).'.php'; |
|
69 | 69 | } |
70 | - if (!file_exists(HTMLPURIFIER_PREFIX . '/' . $file)) { |
|
70 | + if (!file_exists(HTMLPURIFIER_PREFIX.'/'.$file)) { |
|
71 | 71 | return false; |
72 | 72 | } |
73 | 73 | return $file; |
@@ -30,7 +30,7 @@ |
||
30 | 30 | ); |
31 | 31 | return; |
32 | 32 | } |
33 | - $this->_storage[$name] =& $ref; |
|
33 | + $this->_storage[$name] = & $ref; |
|
34 | 34 | } |
35 | 35 | |
36 | 36 | /** |
@@ -25,21 +25,21 @@ |
||
25 | 25 | |
26 | 26 | // ...in NEWS |
27 | 27 | if ($is_dev = (strpos($version, 'dev') === false)) { |
28 | - $date = date('Y-m-d'); |
|
29 | - $news_c = str_replace( |
|
30 | - $l = "$version, unknown release date", |
|
31 | - "$version, released $date", |
|
32 | - file_get_contents('NEWS'), |
|
33 | - $c |
|
34 | - ); |
|
35 | - if (!$c) { |
|
36 | - echo 'Could not update NEWS, missing ' . $l . PHP_EOL; |
|
37 | - exit; |
|
38 | - } elseif ($c > 1) { |
|
39 | - echo 'More than one release declaration in NEWS replaced' . PHP_EOL; |
|
40 | - exit; |
|
41 | - } |
|
42 | - file_put_contents('NEWS', $news_c); |
|
28 | + $date = date('Y-m-d'); |
|
29 | + $news_c = str_replace( |
|
30 | + $l = "$version, unknown release date", |
|
31 | + "$version, released $date", |
|
32 | + file_get_contents('NEWS'), |
|
33 | + $c |
|
34 | + ); |
|
35 | + if (!$c) { |
|
36 | + echo 'Could not update NEWS, missing ' . $l . PHP_EOL; |
|
37 | + exit; |
|
38 | + } elseif ($c > 1) { |
|
39 | + echo 'More than one release declaration in NEWS replaced' . PHP_EOL; |
|
40 | + exit; |
|
41 | + } |
|
42 | + file_put_contents('NEWS', $news_c); |
|
43 | 43 | } |
44 | 44 | |
45 | 45 | // ...in Doxyfile |
@@ -33,10 +33,10 @@ discard block |
||
33 | 33 | $c |
34 | 34 | ); |
35 | 35 | if (!$c) { |
36 | - echo 'Could not update NEWS, missing ' . $l . PHP_EOL; |
|
36 | + echo 'Could not update NEWS, missing '.$l.PHP_EOL; |
|
37 | 37 | exit; |
38 | 38 | } elseif ($c > 1) { |
39 | - echo 'More than one release declaration in NEWS replaced' . PHP_EOL; |
|
39 | + echo 'More than one release declaration in NEWS replaced'.PHP_EOL; |
|
40 | 40 | exit; |
41 | 41 | } |
42 | 42 | file_put_contents('NEWS', $news_c); |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | 1, $c |
51 | 51 | ); |
52 | 52 | if (!$c) { |
53 | - echo 'Could not update Doxyfile, missing PROJECT_NUMBER.' . PHP_EOL; |
|
53 | + echo 'Could not update Doxyfile, missing PROJECT_NUMBER.'.PHP_EOL; |
|
54 | 54 | exit; |
55 | 55 | } |
56 | 56 | file_put_contents('Doxyfile', $doxyfile_c); |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | 1, $c |
65 | 65 | ); |
66 | 66 | if (!$c) { |
67 | - echo 'Could not update HTMLPurifier.php, missing HTML Purifier [version] header.' . PHP_EOL; |
|
67 | + echo 'Could not update HTMLPurifier.php, missing HTML Purifier [version] header.'.PHP_EOL; |
|
68 | 68 | exit; |
69 | 69 | } |
70 | 70 | $htmlpurifier_c = preg_replace( |
@@ -74,7 +74,7 @@ discard block |
||
74 | 74 | 1, $c |
75 | 75 | ); |
76 | 76 | if (!$c) { |
77 | - echo 'Could not update HTMLPurifier.php, missing public $version.' . PHP_EOL; |
|
77 | + echo 'Could not update HTMLPurifier.php, missing public $version.'.PHP_EOL; |
|
78 | 78 | exit; |
79 | 79 | } |
80 | 80 | $htmlpurifier_c = preg_replace( |
@@ -84,7 +84,7 @@ discard block |
||
84 | 84 | 1, $c |
85 | 85 | ); |
86 | 86 | if (!$c) { |
87 | - echo 'Could not update HTMLPurifier.php, missing const $version.' . PHP_EOL; |
|
87 | + echo 'Could not update HTMLPurifier.php, missing const $version.'.PHP_EOL; |
|
88 | 88 | exit; |
89 | 89 | } |
90 | 90 | file_put_contents('library/HTMLPurifier.php', $htmlpurifier_c); |
@@ -97,14 +97,14 @@ discard block |
||
97 | 97 | 1, $c |
98 | 98 | ); |
99 | 99 | if (!$c) { |
100 | - echo 'Could not update Config.php, missing public $version.' . PHP_EOL; |
|
100 | + echo 'Could not update Config.php, missing public $version.'.PHP_EOL; |
|
101 | 101 | exit; |
102 | 102 | } |
103 | 103 | file_put_contents('library/HTMLPurifier/Config.php', $config_c); |
104 | 104 | |
105 | 105 | passthru('php maintenance/flush.php'); |
106 | 106 | |
107 | -if ($is_dev) echo "Review changes, write something in WHATSNEW and FOCUS, and then commit with log 'Release $version.'" . PHP_EOL; |
|
107 | +if ($is_dev) echo "Review changes, write something in WHATSNEW and FOCUS, and then commit with log 'Release $version.'".PHP_EOL; |
|
108 | 108 | else echo "Numbers updated to dev, no other modifications necessary!"; |
109 | 109 | |
110 | 110 | // vim: et sw=4 sts=4 |
@@ -104,7 +104,10 @@ |
||
104 | 104 | |
105 | 105 | passthru('php maintenance/flush.php'); |
106 | 106 | |
107 | -if ($is_dev) echo "Review changes, write something in WHATSNEW and FOCUS, and then commit with log 'Release $version.'" . PHP_EOL; |
|
108 | -else echo "Numbers updated to dev, no other modifications necessary!"; |
|
107 | +if ($is_dev) { |
|
108 | + echo "Review changes, write something in WHATSNEW and FOCUS, and then commit with log 'Release $version.'" . PHP_EOL; |
|
109 | +} else { |
|
110 | + echo "Numbers updated to dev, no other modifications necessary!"; |
|
111 | +} |
|
109 | 112 | |
110 | 113 | // vim: et sw=4 sts=4 |