1212
2017 · featherbb/featherbb@a74cdcd · GitHub
Skip to content

Commit a74cdcd

Browse files
committed
2017
1 parent ad1af56 commit a74cdcd

File tree

168 files changed

+182
-181
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+182
-181
lines changed

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@
2828
"firebase/php-jwt": "^3.0",
2929
"vierbergenlars/php-semver": "^3.0",
3030
"slim/flash": "^0.1.0",
31-
"gettext/gettext": "^4.2"
31+
"gettext/gettext": "^4.2",
32+
"s9e/text-formatter": "^0.9"
3233
},
3334
"support": {
3435
"email": "[email protected]",

featherbb/Controller/Admin/Bans.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Categories.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher.

featherbb/Controller/Admin/Censoring.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Forums.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Groups.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Index.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Maintenance.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Options.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher

featherbb/Controller/Admin/Parser.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
/**
4-
* Copyright (C) 2015-2016 FeatherBB
4+
* Copyright (C) 2015-2017 FeatherBB
55
* based on code by (C) 2008-2015 FluxBB
66
* and Rickard Andersson (C) 2002-2008 PunBB
77
* License: http://www.gnu.org/licenses/gpl.html GPL version 2 or higher
@@ -36,7 +36,7 @@ public function display($req, $res, $args)
3636
if (Input::post('reset') || !file_exists($cache_file)) {
3737
require_once(ForumEnv::get('FEATHER_ROOT').'featherbb/Core/parser/bbcd_source.php');
3838
require_once(ForumEnv::get('FEATHER_ROOT').'featherbb/Core/parser/bbcd_compile.php');
39-
return Router::redirect(Router::pathFor('adminParser'), _e('reset_success'));
39+
return Router::redirect(Router::pathFor('adminParser'), __('reset_success'));
4040
}
4141

4242
// Load the current BBCode $pd array from featherbb/Core/parser/parser_data.inc.php.
@@ -59,28 +59,28 @@ public function display($req, $res, $args)
5959
if (preg_match('%^image/%', $f['type'])) { // If we have an image file type?
6060
if ($f['size'] > 0 && $f['size'] <= ForumSettings::get('o_avatars_size')) {
6161
if (move_uploaded_file($f['tmp_name'], ForumEnv::get('FEATHER_ROOT') .'style/img/smilies/'. $name)) {
62-
return Router::redirect(Router::pathFor('adminParser'), _e('upload success'));
62+
return Router::redirect(Router::pathFor('adminParser'), __('upload success'));
6363
} else { // Error #1: 'Smiley upload failed. Unable to move to smiley folder.'.
64-
throw new Error(_e('upload_err_1'), 500);
64+
throw new Error(__('upload_err_1'), 500);
6565
}
6666
} else { // Error #2: 'Smiley upload failed. File is too big.'
67-
throw new Error(_e('upload_err_2'), 400);
67+
throw new Error(__('upload_err_2'), 400);
6868
}
6969
} else { // Error #3: 'Smiley upload failed. File type is not an image.'.
70-
throw new Error(_e('upload_err_3'), 400);
70+
throw new Error(__('upload_err_3'), 400);
7171
}
7272
} else { // Error #4: 'Smiley upload failed. Bad filename.'
73-
throw new Error(_e('upload_err_4'), 400);
73+
throw new Error(__('upload_err_4'), 400);
7474
}
7575
break;
7676
case 1: // case 1 similar to case 2 so fall through...
77-
case 2: throw new Error(_e('upload_err_2'), 400); // File exceeds MAX_FILE_SIZE.
78-
case 3: throw new Error(_e('upload_err_5'), 400); // File only partially uploaded.
77+
case 2: throw new Error(__('upload_err_2'), 400); // File exceeds MAX_FILE_SIZE.
78+
case 3: throw new Error(__('upload_err_5'), 400); // File only partially uploaded.
7979
// case 4: break; // No error. Normal response when this form element left empty
80-
case 4: throw new Error(_e('upload_err_6'), 400); // No filename.
81-
case 6: throw new Error(_e('upload_err_7'), 500); // No temp folder.
82-
case 7: throw new Error(_e('upload_err_8'), 500); // Cannot write to disk.
83-
default: throw new Error(_e('upload_err_9'), 500); // Generic/unknown error
80+
case 4: throw new Error(__('upload_err_6'), 400); // No filename.
81+
case 6: throw new Error(__('upload_err_7'), 500); // No temp folder.
82+
case 7: throw new Error(__('upload_err_8'), 500); // Cannot write to disk.
83+
default: throw new Error(__('upload_err_9'), 500); // Generic/unknown error
8484
}
8585
}
8686

@@ -193,7 +193,7 @@ public function display($req, $res, $args)
193193
}
194194

195195
require_once('featherbb/Core/parser/bbcd_compile.php'); // Compile $bbcd and save into $pd['bbcd']
196-
return Router::redirect(Router::pathFor('adminParser'), _e('save_success'));
196+
return Router::redirect(Router::pathFor('adminParser'), __('save_success'));
197197
}
198198

199199
AdminUtils::generateAdminMenu('parser');

0 commit comments

Comments
 (0)