diff --git a/adm/style/boardrules_manage_add_edit.html b/adm/style/boardrules_manage_add_edit.html index d366e17a..925f8000 100644 --- a/adm/style/boardrules_manage_add_edit.html +++ b/adm/style/boardrules_manage_add_edit.html @@ -81,7 +81,7 @@

{{ lang('WARNING') }}

{% endif %} -
{{ lang('OPTIONS') ~ lang('COLON') }} {{ BBCODE_STATUS }} :: {{ IMG_STATUS }} :: {{ FLASH_STATUS }} :: {{ URL_STATUS }} :: {{ SMILIES_STATUS }}
+
{{ lang('OPTIONS') ~ lang('COLON') }} {{ BBCODE_STATUS }} :: {{ IMG_STATUS }} :: {{ URL_STATUS }} :: {{ SMILIES_STATUS }}
{% endif %} diff --git a/controller/admin_controller.php b/controller/admin_controller.php index c0fa0287..36d0738a 100644 --- a/controller/admin_controller.php +++ b/controller/admin_controller.php @@ -234,7 +234,7 @@ public function display_language_dashboard() * @param int $parent_id Category to display rules from; default: 0 * @return void * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function display_rules($language, $parent_id = 0) { @@ -514,7 +514,7 @@ protected function get_ruleset_return_url($language, $return_to) * @param int $parent_id Category to display rules from; default: 0 * @return void * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function add_rule($language, $parent_id = 0) { @@ -555,7 +555,7 @@ public function add_rule($language, $parent_id = 0) * @param int $rule_id The rule identifier to edit * @return void * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function edit_rule($rule_id) { @@ -596,7 +596,7 @@ public function edit_rule($rule_id) * @param array $data The form data to be processed * @return void * @access protected - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ protected function add_edit_rule_data($entity, $data) { @@ -632,6 +632,12 @@ protected function add_edit_rule_data($entity, $data) 'anchor' => $data['rule_anchor'], 'message' => $data['rule_message'], ); + $field_labels = array( + 'language' => 'ACP_BOARDRULES_LANGUAGE', + 'title' => 'ACP_RULE_TITLE', + 'anchor' => 'ACP_RULE_ANCHOR', + 'message' => 'ACP_RULE_MESSAGE', + ); // Set the rule's data in the entity foreach ($rule_fields as $entity_function => $rule_data) @@ -640,10 +646,10 @@ protected function add_edit_rule_data($entity, $data) { $entity->{'set_' . $entity_function}($rule_data); } - catch (\phpbb\boardrules\exception\base $e) + catch (\InvalidArgumentException $e) { // Catch exceptions and add them to errors array - $errors[] = $e->get_message($this->lang); + $errors[] = $this->lang->lang($field_labels[$entity_function]) . $this->lang->lang('COLON') . ' ' . $this->lang->lang($e->getMessage()); } } @@ -687,9 +693,9 @@ protected function add_edit_rule_data($entity, $data) { $entity->save(); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\LogicException $e) { - trigger_error($e->get_message($this->lang) . adm_back_link($this->u_action), E_USER_WARNING); + trigger_error($this->lang->lang('RULES_NESTEDSET_INVALID_ITEM') . adm_back_link($this->u_action), E_USER_WARNING); } // Change rule parent @@ -699,9 +705,9 @@ protected function add_edit_rule_data($entity, $data) { $this->rule_operator->change_parent($entity->get_id(), $data['rule_parent_id']); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\OutOfBoundsException $e) { - trigger_error($e->get_message($this->lang) . adm_back_link($this->u_action), E_USER_WARNING); + trigger_error($this->get_rule_error_message($e) . adm_back_link($this->u_action), E_USER_WARNING); } catch (\Exception $e) { @@ -719,9 +725,12 @@ protected function add_edit_rule_data($entity, $data) { $this->rule_operator->add_rule($entity, $data['rule_language'], $data['rule_parent_id']); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\OutOfBoundsException | \LogicException $e) { - trigger_error($e->get_message($this->lang) . adm_back_link($this->u_action), E_USER_WARNING); + $message = $e instanceof \OutOfBoundsException + ? $this->get_rule_error_message($e) + : $this->lang->lang('RULES_NESTEDSET_INVALID_ITEM'); + trigger_error($message . adm_back_link($this->u_action), E_USER_WARNING); } catch (\InvalidArgumentException|\RuntimeException $e) { @@ -754,13 +763,11 @@ protected function add_edit_rule_data($entity, $data) 'BBCODE_STATUS' => $this->lang->lang('BBCODE_IS_ON', '', ''), 'SMILIES_STATUS' => $this->lang->lang('SMILIES_ARE_ON'), 'IMG_STATUS' => $this->lang->lang('IMAGES_ARE_ON'), - 'FLASH_STATUS' => $this->lang->lang('FLASH_IS_ON'), 'URL_STATUS' => $this->lang->lang('URL_IS_ON'), 'S_BBCODE_ALLOWED' => true, 'S_SMILIES_ALLOWED' => true, 'S_BBCODE_IMG' => true, - 'S_BBCODE_FLASH' => true, 'S_LINKS_ALLOWED' => true, )); @@ -789,9 +796,9 @@ public function delete_rule($rule_id) { $this->rule_operator->delete_rule($rule_id); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\OutOfBoundsException $e) { - trigger_error($e->get_message($this->lang) . adm_back_link($this->u_action), E_USER_WARNING); + trigger_error($this->get_rule_error_message($e) . adm_back_link($this->u_action), E_USER_WARNING); } catch (\Exception $e) { @@ -842,9 +849,9 @@ public function move_rule($rule_id, $direction, $amount = 1) { $moved = $this->rule_operator->move($rule_id, $direction, $amount); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\OutOfBoundsException $e) { - trigger_error($e->get_message($this->lang) . adm_back_link($this->u_action), E_USER_WARNING); + trigger_error($this->get_rule_error_message($e) . adm_back_link($this->u_action), E_USER_WARNING); } catch (\Exception $e) { @@ -926,12 +933,27 @@ protected function load_rule($rule_id) { return $this->container->get('phpbb.boardrules.entity')->load($rule_id); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\OutOfBoundsException $e) { - trigger_error($e->get_message($this->lang) . adm_back_link($this->u_action), E_USER_WARNING); + trigger_error($this->get_rule_error_message($e) . adm_back_link($this->u_action), E_USER_WARNING); } } + /** + * Translate a rule lookup or parent validation failure for ACP output. + * + * @param \OutOfBoundsException $exception + * @return string + */ + protected function get_rule_error_message(\OutOfBoundsException $exception) + { + $key = $exception->getMessage() === 'RULE_PARENT_INVALID' + ? 'RULES_NESTEDSET_INVALID_PARENT' + : 'RULES_NESTEDSET_INVALID_ITEM'; + + return $this->lang->lang($key); + } + /** * Assign installed language options and return their dashboard data. * @@ -1009,7 +1031,7 @@ protected function has_copy_source(array $languages, $target_language) * @param int $parent_id Category to display rules from; default: 0 * @return void * @access protected - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ protected function build_parent_select_menu($entity, $parent_id = 0) { diff --git a/controller/admin_interface.php b/controller/admin_interface.php index 9071ec57..1cf4f90b 100644 --- a/controller/admin_interface.php +++ b/controller/admin_interface.php @@ -59,7 +59,7 @@ public function set_ruleset_published($language, $published, $return_to = ''); * @param int $parent_id Category to display rules from; default: 0 * @return void * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function display_rules($language, $parent_id = 0); @@ -78,7 +78,7 @@ public function save_ruleset_intro($language); * @param int $parent_id Category to display rules from; default: 0 * @return void * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function add_rule($language, $parent_id = 0); @@ -88,7 +88,7 @@ public function add_rule($language, $parent_id = 0); * @param int $rule_id The rule identifier to edit * @return void * @access public - * @throws \phpbb\boardrules\exception\base If the rule does not exist or stored rule data is invalid + * @throws \InvalidArgumentException If the rule does not exist or stored rule data is invalid */ public function edit_rule($rule_id); @@ -98,7 +98,7 @@ public function edit_rule($rule_id); * @param int $rule_id The rule identifier to delete * @return void * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds If the rule does not exist + * @throws \OutOfBoundsException If the rule does not exist */ public function delete_rule($rule_id); @@ -110,7 +110,7 @@ public function delete_rule($rule_id); * @param int $amount The number of places to move the rule * @return void * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds If the rule does not exist after moving + * @throws \OutOfBoundsException If the rule does not exist after moving */ public function move_rule($rule_id, $direction, $amount = 1); diff --git a/controller/main_controller.php b/controller/main_controller.php index 17724a8b..43e07542 100644 --- a/controller/main_controller.php +++ b/controller/main_controller.php @@ -69,7 +69,7 @@ public function __construct(\phpbb\config\config $config, \phpbb\controller\help * * @return \Symfony\Component\HttpFoundation\Response A Symfony Response object * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function display() { diff --git a/controller/main_interface.php b/controller/main_interface.php index 44c242ec..18f3e8a0 100644 --- a/controller/main_interface.php +++ b/controller/main_interface.php @@ -22,7 +22,7 @@ interface main_interface * * @return \Symfony\Component\HttpFoundation\Response A Symfony Response object * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function display(); } diff --git a/entity/rule.php b/entity/rule.php index 6ec87b86..3c890d83 100644 --- a/entity/rule.php +++ b/entity/rule.php @@ -64,7 +64,7 @@ public function __construct(\phpbb\db\driver\driver_interface $db, $boardrules_t * @param int $id Rule identifier * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function load($id) { @@ -78,7 +78,7 @@ public function load($id) if ($this->data === false) { // A rule does not exist - throw new \phpbb\boardrules\exception\out_of_bounds('rule_id'); + throw new \OutOfBoundsException('RULE_NOT_FOUND'); } return $this; @@ -95,7 +95,7 @@ public function load($id) * @param array $data Data array, typically from the database * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\base + * @throws \InvalidArgumentException */ public function import($data) { @@ -127,7 +127,7 @@ public function import($data) // If the data wasn't sent to us, throw an exception if (!isset($data[$field])) { - throw new \phpbb\boardrules\exception\invalid_argument(array($field, 'FIELD_MISSING')); + throw new \InvalidArgumentException('RULE_FIELD_MISSING:' . $field); } // If the type is a method on this class, call it @@ -161,7 +161,7 @@ public function import($data) // If the data is less than 0, it's not unsigned and we'll throw an exception if ($this->data[$field] < 0) { - throw new \phpbb\boardrules\exception\out_of_bounds($field); + throw new \InvalidArgumentException('RULE_FIELD_NOT_UNSIGNED:' . $field); } } @@ -176,14 +176,14 @@ public function import($data) * @param string $language The language iso * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \LogicException */ public function insert($language) { if (!empty($this->data['rule_id'])) { // The rule already exists - throw new \phpbb\boardrules\exception\out_of_bounds('rule_id'); + throw new \LogicException('RULE_ALREADY_INSERTED'); } // Resets values required for the nested set system @@ -216,14 +216,14 @@ public function insert($language) * * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \LogicException */ public function save() { if (empty($this->data['rule_id'])) { // The rule does not exist - throw new \phpbb\boardrules\exception\out_of_bounds('rule_id'); + throw new \LogicException('RULE_NOT_INSERTED'); } // Copy the data array, filtering out the rule_id identifier @@ -267,7 +267,7 @@ public function get_title() * @param string $title * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\unexpected_value + * @throws \InvalidArgumentException */ public function set_title($title) { @@ -282,7 +282,7 @@ public function set_title($title) // Enforce the database column length after storage encoding. if (utf8_strlen($title) > 200) { - throw new \phpbb\boardrules\exception\unexpected_value(array('title', 'TOO_LONG')); + throw new \InvalidArgumentException('TOO_LONG'); } // Set the title on our data array @@ -479,7 +479,7 @@ public function get_anchor() * @param string $anchor Anchor text * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\unexpected_value + * @throws \InvalidArgumentException */ public function set_anchor($anchor) { @@ -499,12 +499,12 @@ public function set_anchor($anchor) // Restrict them to BMP letters, marks, numbers, hyphens, and underscores. if (!preg_match('/^(?!.*[\x{10000}-\x{10FFFF}])[\p{L}\p{N}_-][\p{L}\p{M}\p{N}_-]*$/u', $anchor)) { - throw new \phpbb\boardrules\exception\unexpected_value(array('anchor', 'ILLEGAL_CHARACTERS')); + throw new \InvalidArgumentException('ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS'); } if (utf8_strlen($anchor) > 255) { - throw new \phpbb\boardrules\exception\unexpected_value(array('anchor', 'TOO_LONG')); + throw new \InvalidArgumentException('TOO_LONG'); } // Make sure the anchor is unique for the current language. @@ -524,7 +524,7 @@ public function set_anchor($anchor) if ($row) { - throw new \phpbb\boardrules\exception\unexpected_value(array('anchor', 'NOT_UNIQUE')); + throw new \InvalidArgumentException('ACP_BOARDRULES_VALIDATION_NOT_UNIQUE'); } } @@ -551,7 +551,7 @@ public function get_language() * @param string $language language iso * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\unexpected_value + * @throws \InvalidArgumentException */ public function set_language($language) { @@ -569,7 +569,7 @@ public function set_language($language) if (!$lang_id) { - throw new \phpbb\boardrules\exception\unexpected_value(array('rule_language', 'WRONG_DATA_LANG', 'UNEXPECTED_VALUE')); + throw new \InvalidArgumentException('ACP_BOARDRULES_INVALID_LANGUAGE'); } } diff --git a/entity/rule_interface.php b/entity/rule_interface.php index d687bf69..2703caba 100644 --- a/entity/rule_interface.php +++ b/entity/rule_interface.php @@ -23,7 +23,7 @@ interface rule_interface * @param int $id Rule identifier * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function load($id); @@ -37,7 +37,7 @@ public function load($id); * @param array $data Data array, typically from the database * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\base + * @throws \InvalidArgumentException */ public function import($data); @@ -49,7 +49,7 @@ public function import($data); * @param string $language The language iso * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \LogicException */ public function insert($language); @@ -61,7 +61,7 @@ public function insert($language); * * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \LogicException */ public function save(); @@ -87,7 +87,7 @@ public function get_title(); * @param string $title * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\unexpected_value + * @throws \InvalidArgumentException */ public function set_title($title); @@ -203,7 +203,7 @@ public function get_anchor(); * @param string $anchor Anchor text * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\unexpected_value + * @throws \InvalidArgumentException */ public function set_anchor($anchor); @@ -221,7 +221,7 @@ public function get_language(); * @param string $language language iso * @return rule_interface $this object for chaining calls; load()->set()->save() * @access public - * @throws \phpbb\boardrules\exception\unexpected_value If the language is not installed + * @throws \InvalidArgumentException If the language is not installed */ public function set_language($language); diff --git a/exception/base.php b/exception/base.php deleted file mode 100644 index 40afea89..00000000 --- a/exception/base.php +++ /dev/null @@ -1,167 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -namespace phpbb\boardrules\exception; - -/** -* Base exception -*/ -class base extends \Exception -{ - /** - * Null if the message is a string, array if the message was submitted as an array - * @var string|array - */ - protected $message_full; - - protected $previous; - - /** - * Constructor - * - * Different from normal exceptions in that we do not enforce $message to be a string. - * - * @param string|array|null $message - * @param int $code - * @param \Exception|null $previous - * @access public - */ - public function __construct($message = null, $code = 0, \Exception $previous = null) - { - parent::__construct(); - - $this->message = $message; - - if (is_array($message)) - { - $this->message = (string) $message[0]; - } - - // We're slightly changing the way exceptions work - // Tools, such as xDebug, expect the message to be a string, so to prevent errors - // with those tools, we store our full message in message_full and only a string in message - $this->message_full = $message; - - $this->code = $code; - $this->previous = $previous; - } - - /** - * Basic message translation for our exceptions - * - * @param \phpbb\language\language $lang - * @return string - * @access public - */ - public function get_message(\phpbb\language\language $lang) - { - // Make sure our language file has been loaded - $this->add_lang($lang); - - if (is_array($this->message_full)) - { - return call_user_func_array(array($lang, 'lang'), $this->message_full); - } - - return $lang->lang($this->message_full); - } - - /** - * Translate all portions of the message sent to the exception - * - * Goes through each element of the array and tries to translate them - * - * @param \phpbb\language\language $lang - * @param string|array $message_portions The message portions to translate - * @param string|null $parent_message Send a string to translate all of the - * portions with the parent message (typically used to format a string - * with the given message portions). Null to ignore. Default: Null - * @return array|string Array if $parent_message === null else a string - * @access protected - */ - protected function translate_portions(\phpbb\language\language $lang, $message_portions, $parent_message = null) - { - // Make sure our language file has been loaded - $this->add_lang($lang); - - // Ensure we have an array - if (!is_array($message_portions)) - { - $message_portions = array($message_portions); - } - - // Translate each message portion - foreach ($message_portions as &$message) - { - // Attempt to translate each portion - $translated_message = $lang->lang('EXCEPTION_' . $message); - - // Check if translating did anything - if ($translated_message !== 'EXCEPTION_' . $message) - { - // It did, so replace message with the translated version - $message = $translated_message; - } - } - // Always unset a variable passed by reference in a foreach loop - unset($message); - - if ($parent_message !== null) - { - // Prepend the parent message to the message portions - array_unshift($message_portions, (string) $parent_message); - - // We return a string - return call_user_func_array(array($lang, 'lang'), $message_portions); - } - - // We return an array - return $message_portions; - } - - /** - * Add our language file - * - * @param \phpbb\language\language $lang - * @return void - * @access public - */ - public function add_lang(\phpbb\language\language $lang) - { - static $is_loaded = false; - - // We only need to load the language file once - if ($is_loaded) - { - return; - } - - // Add our language file - $lang->add_lang('exceptions', 'phpbb/boardrules'); - - // So the language file is only loaded once - $is_loaded = true; - } - - /** - * Output a string of this error message - * - * This will hopefully be never called, always catch the expected exceptions - * and call get_message to translate them into an error that a user can - * understand - * - * @return string - * @access public - */ - public function __toString() - { - return is_array($this->message_full) ? (string) var_export($this->message_full, true) : (string) $this->message_full; - } -} diff --git a/exception/invalid_argument.php b/exception/invalid_argument.php deleted file mode 100644 index 85289b3a..00000000 --- a/exception/invalid_argument.php +++ /dev/null @@ -1,29 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -namespace phpbb\boardrules\exception; - -/** -* InvalidArgument exception -*/ -class invalid_argument extends base -{ - /** - * Translate this exception - * - * @param \phpbb\language\language $lang - * @return string - * @access public - */ - public function get_message(\phpbb\language\language $lang) - { - return $this->translate_portions($lang, $this->message_full, 'EXCEPTION_INVALID_ARGUMENT'); - } -} diff --git a/exception/out_of_bounds.php b/exception/out_of_bounds.php deleted file mode 100644 index b0c3599f..00000000 --- a/exception/out_of_bounds.php +++ /dev/null @@ -1,29 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -namespace phpbb\boardrules\exception; - -/** -* OutOfBounds exception -*/ -class out_of_bounds extends base -{ - /** - * Translate this exception - * - * @param \phpbb\language\language $lang - * @return string - * @access public - */ - public function get_message(\phpbb\language\language $lang) - { - return $this->translate_portions($lang, $this->message_full, 'EXCEPTION_OUT_OF_BOUNDS'); - } -} diff --git a/exception/unexpected_value.php b/exception/unexpected_value.php deleted file mode 100644 index 4115a58f..00000000 --- a/exception/unexpected_value.php +++ /dev/null @@ -1,29 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -namespace phpbb\boardrules\exception; - -/** -* UnexpectedValue exception -*/ -class unexpected_value extends base -{ - /** - * Translate this exception - * - * @param \phpbb\language\language $lang - * @return string - * @access public - */ - public function get_message(\phpbb\language\language $lang) - { - return $this->translate_portions($lang, $this->message_full, 'EXCEPTION_UNEXPECTED_VALUE'); - } -} diff --git a/language/ar/boardrules_acp.php b/language/ar/boardrules_acp.php index af475036..a7934e73 100644 --- a/language/ar/boardrules_acp.php +++ b/language/ar/boardrules_acp.php @@ -132,6 +132,8 @@ 6 => 'أُعيدت تسمية %d من المراسي المتعارضة باستخدام لواحق رقمية.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'اللغة المحددة غير مثبتة.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'البيانات التي أدخلتها تحتوي على حروف غير مقبولة.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'البيانات المُدخلة موجودة مُسبقاً.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'لا يمكن نشر مجموعة قوانين فارغة أو تغييرها إلى مسودة.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'هل تريد نشر مجموعة القوانين الكاملة لهذه اللغة؟ سيراها مستخدمو هذه اللغة فوراً.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'هل تريد تغيير مجموعة القوانين الكاملة لهذه اللغة إلى مسودة؟ سيرى مستخدمو هذه اللغة قوانين اللغة الافتراضية للمنتدى بدلاً منها.', diff --git a/language/ar/exceptions.php b/language/ar/exceptions.php deleted file mode 100644 index e64633b0..00000000 --- a/language/ar/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'يجب تعبئة الحقل الفارغ', - 'EXCEPTION_INVALID_ARGUMENT' => 'هناك خطأ في البيانات المُحددة لـ `%1$s`. السبب : %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'البيانات المُدخلة في الحقل `%1$s` أكبر من الحد المطلوب', - 'EXCEPTION_TOO_LONG' => 'البيانات المُدخلة أطول من الحد المطلوب.', - 'EXCEPTION_NOT_UNIQUE' => 'البيانات المُدخلة موجودة مُسبقاً.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'هناك خطأ في البيانات المُدخلة في الحقل `%1$s`. السبب : %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'البيانات التي أدخلتها تحتوي على حروف غير مقبولة.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/bg/boardrules_acp.php b/language/bg/boardrules_acp.php index 0c02219c..169958ee 100644 --- a/language/bg/boardrules_acp.php +++ b/language/bg/boardrules_acp.php @@ -115,6 +115,8 @@ 2 => '%d конфликтни котви бяха преименувани с цифрови суфикси.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Избраният език не е инсталиран.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Въведенот съдържа непозволени знаци.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Въведеното не съответства.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Празен набор от правила не може да бъде публикуван или зададен като чернова.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Да се публикува ли този пълен набор от правила? Потребителите на този език ще го видят веднага.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Да се зададе ли този пълен набор от правила като чернова? Потребителите на този език вместо него ще виждат правилата на езика по подразбиране на форума.', diff --git a/language/bg/exceptions.php b/language/bg/exceptions.php deleted file mode 100644 index 32e6e333..00000000 --- a/language/bg/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Липсва исканото поле', - 'EXCEPTION_INVALID_ARGUMENT' => 'Невалиден аргумент даден за `%1$s`. Причина: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Полето `%1$s` получава стойности над границата', - 'EXCEPTION_TOO_LONG' => 'Въведеното в по-дълго от максимално допустимата дължина.', - 'EXCEPTION_NOT_UNIQUE' => 'Въведеното не съответства.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Полето `%1$s` получава неочаквани данни. Причина: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Въведенот съдържа непозволени знаци.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/cs/boardrules_acp.php b/language/cs/boardrules_acp.php index 037cbde7..b598928c 100644 --- a/language/cs/boardrules_acp.php +++ b/language/cs/boardrules_acp.php @@ -119,6 +119,8 @@ 3 => '%d konfliktních odkazů bylo přejmenováno pomocí číselných přípon.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Vybraný jazyk není nainstalován.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Vstup obsahuje neplatné znaky.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Vstup nebyl unikátní.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Prázdnou sadu pravidel nelze zveřejnit ani nastavit jako koncept.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Zveřejnit tuto kompletní jazykovou sadu pravidel? Uživatelé tohoto jazyka ji uvidí okamžitě.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Nastavit tuto kompletní jazykovou sadu pravidel jako koncept? Uživatelé tohoto jazyka místo ní uvidí pravidla ve výchozím jazyce fóra.', diff --git a/language/cs/exceptions.php b/language/cs/exceptions.php deleted file mode 100644 index 7ed68e6d..00000000 --- a/language/cs/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Povinné pole není vypněno', - 'EXCEPTION_INVALID_ARGUMENT' => 'Neplatný argument specifikován pro `%1$s`. Důvod: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Pole `%1$s` obdrželo data mimo svůj rozsah', - 'EXCEPTION_TOO_LONG' => 'Vstup překročil maximální povolenou délku.', - 'EXCEPTION_NOT_UNIQUE' => 'Vstup nebyl unikátní.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Pole `%1$s` obdrželo neočekávaná data. Důvod: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Vstup obsahuje neplatné znaky.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/da/boardrules_acp.php b/language/da/boardrules_acp.php index 8e1bbe74..8d0174b5 100644 --- a/language/da/boardrules_acp.php +++ b/language/da/boardrules_acp.php @@ -115,6 +115,8 @@ 2 => '%d ankre med konflikter blev omdøbt med numeriske suffikser.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Det valgte sprog er ikke installeret.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Inputtet indeholdt tegn som ikke er tilladt.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Inputtet var ikke unikt.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Et tomt regelsæt kan ikke udgives eller angives som kladde.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Vil du udgive hele dette regelsæt? Brugere af dette sprog vil se det med det samme.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Vil du ændre hele dette regelsæt til en kladde? Brugere af dette sprog vil i stedet se reglerne på boardets standardsprog.', diff --git a/language/da/exceptions.php b/language/da/exceptions.php deleted file mode 100644 index ce85acd0..00000000 --- a/language/da/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Obligatorisk felt mangler', - 'EXCEPTION_INVALID_ARGUMENT' => 'Ugyldigt argument angivet til `%1$s`. Årsag: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Feltet `%1$s` modtog data udover dets grænser', - 'EXCEPTION_TOO_LONG' => 'Inputtet var længere end den maksimale længde.', - 'EXCEPTION_NOT_UNIQUE' => 'Inputtet var ikke unikt.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Feltet `%1$s` modtog uventede data. Årsag: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Inputtet indeholdt tegn som ikke er tilladt.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/de/boardrules_acp.php b/language/de/boardrules_acp.php index 04546de2..727ebd03 100644 --- a/language/de/boardrules_acp.php +++ b/language/de/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d Anker mit Konflikten wurden mit numerischen Suffixen umbenannt.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Die ausgewählte Sprache ist nicht installiert.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Die Eingabe enthält für dieses Feld nicht zulässige Zeichen.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Uneindeutige Eingabe (Bezeichnung gegebenenfalls bereits vergeben).', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Ein leerer Regelsatz kann weder veröffentlicht noch als Entwurf festgelegt werden.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Diesen vollständigen Sprachregelsatz veröffentlichen? Benutzer dieser Sprache sehen ihn sofort.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Diesen vollständigen Sprachregelsatz als Entwurf festlegen? Benutzer dieser Sprache sehen stattdessen die Regeln in der Standardsprache des Forums.', diff --git a/language/de/exceptions.php b/language/de/exceptions.php deleted file mode 100644 index dfb7e784..00000000 --- a/language/de/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Erforderliches Feld fehlt', - 'EXCEPTION_INVALID_ARGUMENT' => 'Ungültige Eingabe in `%1$s`. Grund: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Feld `%1$s` enthält unzulässige Zeichen', - 'EXCEPTION_TOO_LONG' => 'Die Eingabe ist länger als maximal zulässig.', - 'EXCEPTION_NOT_UNIQUE' => 'Uneindeutige Eingabe (Bezeichnung gegebenenfalls bereits vergeben).', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Unerwartete Zeichen in Feld `%1$s`. Grund: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Die Eingabe enthält für dieses Feld nicht zulässige Zeichen.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/de_x_sie/boardrules_acp.php b/language/de_x_sie/boardrules_acp.php index bc13bc6e..5f8dc7f7 100644 --- a/language/de_x_sie/boardrules_acp.php +++ b/language/de_x_sie/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d Anker mit Konflikten wurden mit numerischen Suffixen umbenannt.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Die ausgewählte Sprache ist nicht installiert.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Die Eingabe enthält für dieses Feld nicht zulässige Zeichen.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Uneindeutige Eingabe (Bezeichnung gegebenenfalls bereits vergeben).', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Ein leerer Regelsatz kann weder veröffentlicht noch als Entwurf festgelegt werden.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Diesen vollständigen Sprachregelsatz veröffentlichen? Benutzer dieser Sprache sehen ihn sofort.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Diesen vollständigen Sprachregelsatz als Entwurf festlegen? Benutzer dieser Sprache sehen stattdessen die Regeln in der Standardsprache des Forums.', diff --git a/language/de_x_sie/exceptions.php b/language/de_x_sie/exceptions.php deleted file mode 100644 index 0400f139..00000000 --- a/language/de_x_sie/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Erforderliches Feld fehlt', - 'EXCEPTION_INVALID_ARGUMENT' => 'Ungültige Eingabe in `%1$s`. Grund: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Das Feld `%1$s` enthält unzulässige Zeichen', - 'EXCEPTION_TOO_LONG' => 'Die Eingabe ist länger als maximal zulässig.', - 'EXCEPTION_NOT_UNIQUE' => 'Uneindeutige Eingabe (Bezeichnung gegebenenfalls bereits vergeben).', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Unerwartete Zeichen in Feld `%1$s`. Grund: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Die Eingabe enthält für dieses Feld nicht zulässige Zeichen.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/el/boardrules_acp.php b/language/el/boardrules_acp.php index 79dc0101..7a49a106 100644 --- a/language/el/boardrules_acp.php +++ b/language/el/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d άγκυρες με διένεξη μετονομάστηκαν με αριθμητικά επιθήματα.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Η επιλεγμένη γλώσσα δεν είναι εγκατεστημένη.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Η εισαχθείσα τιμή περιείχε μη επιτρεπτούς χαρακτήρες.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Η εισαχθείσα τιμή δεν ήταν μοναδική.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Ένα κενό σύνολο κανόνων δεν μπορεί να δημοσιευτεί ή να μετατραπεί σε πρόχειρο.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Να δημοσιευτεί το πλήρες σύνολο κανόνων αυτής της γλώσσας; Οι χρήστες αυτής της γλώσσας θα το δουν αμέσως.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Να μετατραπεί το πλήρες σύνολο κανόνων αυτής της γλώσσας σε πρόχειρο; Οι χρήστες αυτής της γλώσσας θα βλέπουν αντί γι’ αυτό τους κανόνες στην προεπιλεγμένη γλώσσα της κοινότητας.', diff --git a/language/el/exceptions.php b/language/el/exceptions.php deleted file mode 100644 index 2854d32b..00000000 --- a/language/el/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Ένα απαιτούμενο πεδίο λείπει', - 'EXCEPTION_INVALID_ARGUMENT' => 'Μη έγκυρο όρισμα καθορίστηκε για "%1$s". Λόγος: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Το πεδίο "%1$s" δέχτηκε δεδομένα εκτός ορίου', - 'EXCEPTION_TOO_LONG' => 'Η εισαχθείσα τιμή ήταν μεγαλύτερη από το μέγιστο μήκος.', - 'EXCEPTION_NOT_UNIQUE' => 'Η εισαχθείσα τιμή δεν ήταν μοναδική.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Το πεδίο "%1$s" δέχτηκε μη αναμενόμενα δεδομένα. Λόγος: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Η εισαχθείσα τιμή περιείχε μη επιτρεπτούς χαρακτήρες.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/en/boardrules_acp.php b/language/en/boardrules_acp.php index b76eb819..44559ebb 100644 --- a/language/en/boardrules_acp.php +++ b/language/en/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d conflicting anchors were renamed with numeric suffixes.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Selected language is not installed.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'The input contained illegal characters.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'The input was not unique.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'An empty ruleset cannot be published or changed to draft.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publish this complete language ruleset? Users of this language will see it immediately.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Change this complete language ruleset to draft? Users of this language will see rules from the board’s default language instead.', diff --git a/language/en/exceptions.php b/language/en/exceptions.php deleted file mode 100644 index b38731cc..00000000 --- a/language/en/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Required field missing', - 'EXCEPTION_INVALID_ARGUMENT' => 'Invalid argument specified for `%1$s`. Reason: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'The field `%1$s` received data beyond its bounds', - 'EXCEPTION_TOO_LONG' => 'The input was longer than the maximum length.', - 'EXCEPTION_NOT_UNIQUE' => 'The input was not unique.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'The field `%1$s` received unexpected data. Reason: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'The input contained illegal characters.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/es/boardrules_acp.php b/language/es/boardrules_acp.php index 01d119dc..eb9fb2a0 100644 --- a/language/es/boardrules_acp.php +++ b/language/es/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => 'Se cambiaron los nombres de %d anclajes en conflicto con sufijos numéricos.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'El idioma seleccionado no está instalado.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'La entrada contiene caracteres no válidos.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'La entrada no es única.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Un conjunto de normas vacío no se puede publicar ni establecer como borrador.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => '¿Publicar este conjunto completo de normas del idioma? Los usuarios de este idioma lo verán inmediatamente.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => '¿Establecer este conjunto completo de normas del idioma como borrador? Los usuarios de este idioma verán en su lugar las normas del idioma predeterminado del sitio.', diff --git a/language/es/exceptions.php b/language/es/exceptions.php deleted file mode 100644 index aad37cae..00000000 --- a/language/es/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Falta un campo requerido', - 'EXCEPTION_INVALID_ARGUMENT' => 'Argumento no válido para `%1$s`. Razón: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'El campo `%1$s` tiene datos recibidos más allá de sus límites', - 'EXCEPTION_TOO_LONG' => 'La entrada era más larga que la longitud máxima.', - 'EXCEPTION_NOT_UNIQUE' => 'La entrada no es única.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'El campo `%1$s` ha recibido datos inesperados. Razón: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'La entrada contiene caracteres no válidos.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/et/boardrules_acp.php b/language/et/boardrules_acp.php index 756dffe9..1df63386 100644 --- a/language/et/boardrules_acp.php +++ b/language/et/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d konfliktset ankrut nimetati ümber numbriliste järelliidetega.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Valitud keel pole paigaldatud.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Sisend sisaldab keelatuid sümboleid.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Sisend ei olnud unikaalne.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Tühja reeglistikku ei saa avaldada ega mustandiks muuta.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Kas avaldada selle keele täielik reeglistik? Selle keele kasutajad näevad seda kohe.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Kas muuta selle keele täielik reeglistik mustandiks? Selle keele kasutajad näevad selle asemel foorumi vaikekeele reegleid.', diff --git a/language/et/exceptions.php b/language/et/exceptions.php deleted file mode 100644 index a890fcdd..00000000 --- a/language/et/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* -* @copyright (c) 2014 phpBB Limited -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Nõutud väli puudub', - 'EXCEPTION_INVALID_ARGUMENT' => 'Vigane argument `%1$s`. Põhjus: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Väli `%1$s` sai andmed väljast poolt oma piire', - 'EXCEPTION_TOO_LONG' => 'Sisend oli pikem kui maksimum pikkus.', - 'EXCEPTION_NOT_UNIQUE' => 'Sisend ei olnud unikaalne.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Väli `%1$s` sai ootamatud andmed. Põhjus: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Sisend sisaldab keelatuid sümboleid.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/fi/boardrules_acp.php b/language/fi/boardrules_acp.php index b77c3684..f1a49542 100644 --- a/language/fi/boardrules_acp.php +++ b/language/fi/boardrules_acp.php @@ -115,6 +115,8 @@ 2 => '%d ristiriitaista ankkuria nimettiin uudelleen numeerisilla jälkiliitteillä.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Valittua kieltä ei ole asennettu.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Syöte sisälsi ei-sallittuja merkkejä.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Syöte ei ollut ainutlaatuinen.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Tyhjää sääntökokonaisuutta ei voi julkaista tai muuttaa luonnokseksi.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Julkaistaanko tämän kielen koko sääntökokonaisuus? Tämän kielen käyttäjät näkevät sen heti.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Muutetaanko tämän kielen koko sääntökokonaisuus luonnokseksi? Tämän kielen käyttäjät näkevät sen sijaan foorumin oletuskielen säännöt.', diff --git a/language/fi/exceptions.php b/language/fi/exceptions.php deleted file mode 100644 index e68c98cc..00000000 --- a/language/fi/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Vaadittu kenttä puuttuu', - 'EXCEPTION_INVALID_ARGUMENT' => 'Virheellinen argumentti arvolle `%1$s`. Syy: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Kenttää `%1$s` ei mahdu enempää dataa.', - 'EXCEPTION_TOO_LONG' => 'Syöttämäsi tieto oli pitempi kuin sallittu enimmäispituus.', - 'EXCEPTION_NOT_UNIQUE' => 'Syöte ei ollut ainutlaatuinen.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Kenttä `%1$s` sai odottamattomia tietoja. Syy: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Syöte sisälsi ei-sallittuja merkkejä.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/fr/boardrules_acp.php b/language/fr/boardrules_acp.php index 2b31eda6..2c83315b 100644 --- a/language/fr/boardrules_acp.php +++ b/language/fr/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d ancres en conflit ont été renommées avec des suffixes numériques.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'La langue sélectionnée n’est pas installée.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'La donnée contenait des caractères interdits.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'La donnée n’était pas unique.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Un ensemble de règles vide ne peut être ni publié ni défini comme brouillon.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publier cet ensemble complet de règles linguistiques ? Les utilisateurs de cette langue le verront immédiatement.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Définir cet ensemble complet de règles linguistiques comme brouillon ? Les utilisateurs de cette langue verront à la place les règles dans la langue par défaut du forum.', diff --git a/language/fr/exceptions.php b/language/fr/exceptions.php deleted file mode 100644 index 34b2ddeb..00000000 --- a/language/fr/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Un champ obligatoire est manquant', - 'EXCEPTION_INVALID_ARGUMENT' => 'Argument incorrect spécifié pour `%1$s`. Motif : %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Le champ `%1$s` a reçu une donnée incohérente', - 'EXCEPTION_TOO_LONG' => 'La donnée saisie était plus longue que la longueur maximale possible.', - 'EXCEPTION_NOT_UNIQUE' => 'La donnée n’était pas unique.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Le champ `%1$s` a reçu une donnée inattendue. Motif : %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'La donnée contenait des caractères interdits.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/he/boardrules_acp.php b/language/he/boardrules_acp.php index c292c3d5..15359166 100644 --- a/language/he/boardrules_acp.php +++ b/language/he/boardrules_acp.php @@ -115,6 +115,8 @@ 2 => '%d עוגנים מתנגשים קיבלו שמות חדשים עם סיומות מספריות.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'השפה שנבחרה אינה מותקנת.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'התוכן הכיל תווים לא חוקיים.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'התוכן לא היה ייחודי.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'אי אפשר לפרסם מערכת חוקים ריקה או להפוך אותה לטיוטה.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'לפרסם את מערכת החוקים המלאה בשפה זו? משתמשי השפה יראו אותה מיד.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'להפוך את מערכת החוקים המלאה בשפה זו לטיוטה? משתמשי השפה יראו במקומה את החוקים בשפת ברירת המחדל של הפורום.', diff --git a/language/he/exceptions.php b/language/he/exceptions.php deleted file mode 100644 index b4c7ad08..00000000 --- a/language/he/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'שדה נדרש חסר', - 'EXCEPTION_INVALID_ARGUMENT' => 'תוכן לא רלוונטי הוגדר עבור `%1$s`. סיבה: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'השדה `%1$s` קיבל מידע חורג', - 'EXCEPTION_TOO_LONG' => 'התוכן באורך גדול מדי.', - 'EXCEPTION_NOT_UNIQUE' => 'התוכן לא היה ייחודי.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'השדה `%1$s` קיבל מידע לא-צפוי. סיבה: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'התוכן הכיל תווים לא חוקיים.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/hr/boardrules_acp.php b/language/hr/boardrules_acp.php index 82edeb22..0d624283 100644 --- a/language/hr/boardrules_acp.php +++ b/language/hr/boardrules_acp.php @@ -120,6 +120,8 @@ 3 => '%d podudarnih sidara preimenovano je pomoću brojčanih sufiksa.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Odabrani jezik nije instaliran.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Upis sadrži nedopuštene znakove.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Upis nije jedinstven.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Prazan skup pravila ne može se objaviti niti postaviti kao skica.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Objaviti cijeli skup pravila za ovaj jezik? Korisnici ovog jezika odmah će ga vidjeti.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Postaviti cijeli skup pravila za ovaj jezik kao skicu? Korisnici ovog jezika umjesto njega vidjet će pravila na zadanom jeziku foruma.', diff --git a/language/hr/exceptions.php b/language/hr/exceptions.php deleted file mode 100644 index 32e81c04..00000000 --- a/language/hr/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Nedostaje traženo polje.', - 'EXCEPTION_INVALID_ARGUMENT' => 'Određen je neispravan argument za `%1$s`.
Razlog: %2$s.', - 'EXCEPTION_OUT_OF_BOUNDS' => 'U polje `%1$s` su upisani podatci van njegovih granica.', - 'EXCEPTION_TOO_LONG' => 'Upis je duži od maksimalne dužine.', - 'EXCEPTION_NOT_UNIQUE' => 'Upis nije jedinstven.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'U polje `%1$s` su upisani neočekivani podatci.
Razlog: %2$s.', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Upis sadrži nedopuštene znakove.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/hu/boardrules_acp.php b/language/hu/boardrules_acp.php index d28344b1..c65df075 100644 --- a/language/hu/boardrules_acp.php +++ b/language/hu/boardrules_acp.php @@ -115,6 +115,8 @@ 2 => '%d ütköző horgony számozott utótaggal lett átnevezve.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'A kiválasztott nyelv nincs telepítve.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'A bemenet érvénytelen karaktereket tartalmazott.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'A bemenet nem volt egyedi.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Üres szabálykészlet nem tehető közzé és nem állítható piszkozatként.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Közzéteszi a teljes szabálykészletet ezen a nyelven? Az ezt a nyelvet használók azonnal látni fogják.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Piszkozattá teszi a teljes szabálykészletet ezen a nyelven? Az ezt a nyelvet használók helyette a fórum alapértelmezett nyelvén létrehozott szabályokat fogják látni.', diff --git a/language/hu/exceptions.php b/language/hu/exceptions.php deleted file mode 100644 index 761b93df..00000000 --- a/language/hu/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'A szükséges mező hiányzik', - 'EXCEPTION_INVALID_ARGUMENT' => 'Érvénytelen argumentum ehhez: `%1$s`. Ok: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => '`%1$s` mező későn kapott adatokat.', - 'EXCEPTION_TOO_LONG' => 'A bemenet hosszabb volt, mint a maximális hossz.', - 'EXCEPTION_NOT_UNIQUE' => 'A bemenet nem volt egyedi.', - 'EXCEPTION_UNEXPECTED_VALUE' => '`%1$s` mező váratlan adatokat kapott. Ok: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'A bemenet érvénytelen karaktereket tartalmazott.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/it/boardrules_acp.php b/language/it/boardrules_acp.php index ab183f2b..0fa69f32 100644 --- a/language/it/boardrules_acp.php +++ b/language/it/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d ancoraggi in conflitto sono stati rinominati con suffissi numerici.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'La lingua selezionata non è installata.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'La voce contiene caratteri non validi.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'La voce non era unica.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Un set di regole vuoto non può essere pubblicato né impostato come bozza.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Pubblicare questo set completo di regole della lingua? Gli utenti di questa lingua lo vedranno immediatamente.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Impostare questo set completo di regole della lingua come bozza? Gli utenti di questa lingua vedranno invece le regole nella lingua predefinita della board.', diff --git a/language/it/exceptions.php b/language/it/exceptions.php deleted file mode 100644 index 66469ef0..00000000 --- a/language/it/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Campo obbligatorio mancante', - 'EXCEPTION_INVALID_ARGUMENT' => 'Parametro specificato non valido `%1$s`. Motivo: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Il campo `%1$s` ha ricevuto oltre i limiti consentiti', - 'EXCEPTION_TOO_LONG' => 'La voce è più lunga del limite massimo.', - 'EXCEPTION_NOT_UNIQUE' => 'La voce non era unica.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Il campo `%1$s` ha ricevuto dati inaspet. Motivo: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'La voce contiene caratteri non validi.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/nb/boardrules_acp.php b/language/nb/boardrules_acp.php index 10a1a12a..f57bdf83 100644 --- a/language/nb/boardrules_acp.php +++ b/language/nb/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d ankere med konflikter fikk nye navn med numeriske suffikser.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Det valgte språket er ikke installert.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Inndata inneholdt tegn som ikke er tillatt.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Inndata var ikke unike.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Et tomt regelsett kan ikke publiseres eller angis som utkast.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publisere hele dette regelsettet? Brukere av dette språket vil se det umiddelbart.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Endre hele dette regelsettet til utkast? Brukere av dette språket vil i stedet se reglene på forumets standardspråk.', diff --git a/language/nb/exceptions.php b/language/nb/exceptions.php deleted file mode 100644 index 0d60bfe0..00000000 --- a/language/nb/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Obligatorisk felt mangler', - 'EXCEPTION_INVALID_ARGUMENT' => 'Ugylding innhold angitt for `%1$s`. Årsak: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Feltet `%1$s` har data utover feltets begrensninger', - 'EXCEPTION_TOO_LONG' => 'Inndata var lengre enn den maksimalt tillate lengden.', - 'EXCEPTION_NOT_UNIQUE' => 'Inndata var ikke unike.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Uventede data mottatt i feltet `%1$s`. Årsak: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Inndata inneholdt tegn som ikke er tillatt.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/nl/boardrules_acp.php b/language/nl/boardrules_acp.php index 172383f7..41bdffdc 100644 --- a/language/nl/boardrules_acp.php +++ b/language/nl/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d conflicterende ankers zijn hernoemd met numerieke achtervoegsels.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'De geselecteerde taal is niet geïnstalleerd.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'De invoer bevat ongeldige tekens.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'De invoer is niet uniek.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Een lege regelset kan niet worden gepubliceerd of als concept worden ingesteld.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Deze volledige regelset publiceren? Gebruikers van deze taal zien deze onmiddellijk.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Deze volledige regelset als concept instellen? Gebruikers van deze taal zien in plaats daarvan de regels in de standaardtaal van het forum.', diff --git a/language/nl/exceptions.php b/language/nl/exceptions.php deleted file mode 100644 index 2f9aaba9..00000000 --- a/language/nl/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Vereist veld mist', - 'EXCEPTION_INVALID_ARGUMENT' => 'Ongeldig argument gespecificeerd voor `%1$s`. Reden: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Het veld `%1$s` ontvangt data wat buiten zijn bereik ligt', - 'EXCEPTION_TOO_LONG' => 'De invoer was langer dan de maximum lengte.', - 'EXCEPTION_NOT_UNIQUE' => 'De invoer is niet uniek.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Het veld `%1$s` ontvangt onverwachte data. Reden: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'De invoer bevat ongeldige tekens.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/pl/boardrules_acp.php b/language/pl/boardrules_acp.php index e4e7f5fe..90cd1558 100644 --- a/language/pl/boardrules_acp.php +++ b/language/pl/boardrules_acp.php @@ -120,6 +120,8 @@ 3 => 'Zmieniono nazwy %d zakotwiczeń powodujących konflikt, dodając przyrostki liczbowe.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Wybrany język nie jest zainstalowany.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Wprowadzone dane zawierały niedozwolone znaki.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Wprowadzone dane nie były unikalne.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Pustego regulaminu nie można opublikować ani ustawić jako szkic.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Opublikować ten kompletny regulamin języka? Użytkownicy tego języka zobaczą go natychmiast.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Ustawić ten kompletny regulamin języka jako szkic? Użytkownicy tego języka zobaczą zamiast niego regulamin w domyślnym języku forum.', diff --git a/language/pl/exceptions.php b/language/pl/exceptions.php deleted file mode 100644 index 18eb292d..00000000 --- a/language/pl/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Brak wymaganego pola', - 'EXCEPTION_INVALID_ARGUMENT' => 'Nieprawidłowy argument określony dla `%1$s`. Powód: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Pole `%1$s` odebrało dane poza jego granicami', - 'EXCEPTION_TOO_LONG' => 'Wprowadzone dane były dłuższe niż maksymalna długość.', - 'EXCEPTION_NOT_UNIQUE' => 'Wprowadzone dane nie były unikalne.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Pole `%1$s` odebrało nieoczekiwane dane. Powód: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Wprowadzone dane zawierały niedozwolone znaki.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/pt/boardrules_acp.php b/language/pt/boardrules_acp.php index 1d5e5b3f..e565f806 100644 --- a/language/pt/boardrules_acp.php +++ b/language/pt/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d âncoras em conflito foram renomeadas com sufixos numéricos.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'O idioma selecionado não está instalado.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'A entrada tem caracteres inválidos.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'A entrada não é única.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Um conjunto de regras vazio não pode ser publicado nem definido como rascunho.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publicar este conjunto completo de regras do idioma? Os utilizadores deste idioma irão vê-lo imediatamente.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Definir este conjunto completo de regras do idioma como rascunho? Os utilizadores deste idioma verão as regras no idioma predefinido do fórum.', diff --git a/language/pt/exceptions.php b/language/pt/exceptions.php deleted file mode 100644 index a3a4a29f..00000000 --- a/language/pt/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Campo obrigatório em falta', - 'EXCEPTION_INVALID_ARGUMENT' => 'O argumento especificado para `%1$s` é inválido. Razão: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'O Campo `%1$s` recebeu dados além do limite', - 'EXCEPTION_TOO_LONG' => 'A entrada foi maior do que o máximo permitido.', - 'EXCEPTION_NOT_UNIQUE' => 'A entrada não é única.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'O campo `%1$s` recebeu dados não previstos. Razão: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'A entrada tem caracteres inválidos.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/pt_br/boardrules_acp.php b/language/pt_br/boardrules_acp.php index 344cd529..aaf22a99 100644 --- a/language/pt_br/boardrules_acp.php +++ b/language/pt_br/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d âncoras em conflito foram renomeadas com sufixos numéricos.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'O idioma selecionado não está instalado.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'A entrada tem caracteres inválidos.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'A entrada não é única.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Um conjunto de regras vazio não pode ser publicado nem definido como rascunho.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publicar este conjunto completo de regras do idioma? Os usuários deste idioma o verão imediatamente.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Definir este conjunto completo de regras do idioma como rascunho? Os usuários deste idioma verão as regras no idioma padrão do fórum.', diff --git a/language/pt_br/exceptions.php b/language/pt_br/exceptions.php deleted file mode 100644 index ae455e57..00000000 --- a/language/pt_br/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Campo obrigatório faltante', - 'EXCEPTION_INVALID_ARGUMENT' => 'O argumento especificado para `%1$s` é inválido. Razão: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'O Campo `%1$s` recebeu dados além do limite', - 'EXCEPTION_TOO_LONG' => 'A entrada foi maior do que o máximo permitido.', - 'EXCEPTION_NOT_UNIQUE' => 'A entrada não é única.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'O campo `%1$s` recebeu dados não previstos. Razão: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'A entrada tem caracteres inválidos.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/pt_preao/boardrules_acp.php b/language/pt_preao/boardrules_acp.php index e2fb8408..46dd4212 100644 --- a/language/pt_preao/boardrules_acp.php +++ b/language/pt_preao/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d âncoras em conflito foram renomeadas com sufixos numéricos.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'O idioma seleccionado não está instalado.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'A entrada tem caracteres inválidos.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'A entrada não é única.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Um conjunto de regras vazio não pode ser publicado nem definido como rascunho.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publicar este conjunto completo de regras do idioma? Os utilizadores deste idioma irão vê-lo imediatamente.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Definir este conjunto completo de regras do idioma como rascunho? Os utilizadores deste idioma verão as regras no idioma predefinido do fórum.', diff --git a/language/pt_preao/exceptions.php b/language/pt_preao/exceptions.php deleted file mode 100644 index a3a4a29f..00000000 --- a/language/pt_preao/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Campo obrigatório em falta', - 'EXCEPTION_INVALID_ARGUMENT' => 'O argumento especificado para `%1$s` é inválido. Razão: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'O Campo `%1$s` recebeu dados além do limite', - 'EXCEPTION_TOO_LONG' => 'A entrada foi maior do que o máximo permitido.', - 'EXCEPTION_NOT_UNIQUE' => 'A entrada não é única.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'O campo `%1$s` recebeu dados não previstos. Razão: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'A entrada tem caracteres inválidos.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/ro/boardrules_acp.php b/language/ro/boardrules_acp.php index b6d3c51d..cad413ce 100644 --- a/language/ro/boardrules_acp.php +++ b/language/ro/boardrules_acp.php @@ -119,6 +119,8 @@ 3 => '%d ancore aflate în conflict au fost redenumite cu sufixe numerice.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Limba selectată nu este instalată.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Campurile contin caractere nepermise.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Campul nu este unic.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Un set de reguli gol nu poate fi publicat sau schimbat în ciornă.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publicați setul complet de reguli al acestei limbi? Utilizatorii acestei limbi îl vor vedea imediat.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Schimbați setul complet de reguli al acestei limbi în ciornă? Utilizatorii acestei limbi vor vedea în schimb regulile în limba implicită a forumului.', diff --git a/language/ro/exceptions.php b/language/ro/exceptions.php deleted file mode 100644 index 2139d251..00000000 --- a/language/ro/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Campurile necesare nu sunt completate', - 'EXCEPTION_INVALID_ARGUMENT' => 'Argument invalid pentru `%1$s`. Motiv: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Campul `%1$s` a primit date mai mari decat limitele sale', - 'EXCEPTION_TOO_LONG' => 'Ai introdus un camp prea lung fata de maxima admisa.', - 'EXCEPTION_NOT_UNIQUE' => 'Campul nu este unic.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Campul `%1$s` date neasteptate primite. Motiv: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Campurile contin caractere nepermise.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/ru/boardrules_acp.php b/language/ru/boardrules_acp.php index acaf1069..6ca3568f 100644 --- a/language/ru/boardrules_acp.php +++ b/language/ru/boardrules_acp.php @@ -119,6 +119,8 @@ 3 => '%d конфликтующих якорей переименовано с добавлением числовых суффиксов.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Выбранный язык не установлен.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Введеная строка содержит некорректные символы.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Значение не уникально.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Пустой набор правил нельзя опубликовать или сделать черновиком.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Опубликовать этот полный набор правил языка? Пользователи этого языка увидят его немедленно.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Сделать этот полный набор правил языка черновиком? Пользователи этого языка вместо него увидят правила на языке форума по умолчанию.', diff --git a/language/ru/exceptions.php b/language/ru/exceptions.php deleted file mode 100644 index d7a5d9d7..00000000 --- a/language/ru/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Обязательное поле незаполнено', - 'EXCEPTION_INVALID_ARGUMENT' => 'Некорректное значение в поле `%1$s`. Причина: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'В поле `%1$s` находится значение, выходящее за рамки допустимых', - 'EXCEPTION_TOO_LONG' => 'Введенная строка длиннее максимума.', - 'EXCEPTION_NOT_UNIQUE' => 'Значение не уникально.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Некорректное значение в поле `%1$s`. Причина: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Введеная строка содержит некорректные символы.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/sk/boardrules_acp.php b/language/sk/boardrules_acp.php index 067d3df9..33ad78ac 100644 --- a/language/sk/boardrules_acp.php +++ b/language/sk/boardrules_acp.php @@ -119,6 +119,8 @@ 3 => '%d konfliktných odkazov bolo premenovaných pomocou číselných prípon.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Vybraný jazyk nie je nainštalovaný.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Vstup obsahuje neplatné znaky.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Vstup nebol jedinečný.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Prázdnu sadu pravidiel nemožno zverejniť ani nastaviť ako koncept.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Zverejniť túto kompletnú jazykovú sadu pravidiel? Používatelia tohto jazyka ju uvidia okamžite.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Nastaviť túto kompletnú jazykovú sadu pravidiel ako koncept? Používatelia tohto jazyka namiesto nej uvidia pravidlá v predvolenom jazyku fóra.', diff --git a/language/sk/exceptions.php b/language/sk/exceptions.php deleted file mode 100644 index 9268837f..00000000 --- a/language/sk/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Povinné pole nie je vyplnené', - 'EXCEPTION_INVALID_ARGUMENT' => 'Neplatný argument zadaný pre `%1$s`. Dôvod: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Pole `%1$s` obdržalo dáta mimo svoj rozsah', - 'EXCEPTION_TOO_LONG' => 'Vstup prekročil maximálnu povolenú dĺžku.', - 'EXCEPTION_NOT_UNIQUE' => 'Vstup nebol jedinečný.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Pole `%1$s` obdržalo neočakávané dáta. Dôvod: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Vstup obsahuje neplatné znaky.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/sv/boardrules_acp.php b/language/sv/boardrules_acp.php index fe749321..63dce44b 100644 --- a/language/sv/boardrules_acp.php +++ b/language/sv/boardrules_acp.php @@ -116,6 +116,8 @@ 2 => '%d ankare med konflikter döptes om med numeriska suffix.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Det valda språket är inte installerat.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Inmatningen innehöll otillåtna tecken.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Inmatningen var ej unik.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'En tom regeluppsättning kan inte publiceras eller anges som utkast.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Publicera hela denna regeluppsättning? Användare av detta språk ser den omedelbart.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Ändra hela denna regeluppsättning till utkast? Användare av detta språk ser i stället reglerna på forumets standardspråk.', diff --git a/language/sv/exceptions.php b/language/sv/exceptions.php deleted file mode 100644 index 20779885..00000000 --- a/language/sv/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Erforderligt fält saknas', - 'EXCEPTION_INVALID_ARGUMENT' => 'Ogiltigt argument angivet för `%1$s`. Orsak: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'Fältet `%1$s` har mottagit data utöver fältets begränsningar', - 'EXCEPTION_TOO_LONG' => 'Inmatningen var längre än den maximalt tillåta längden.', - 'EXCEPTION_NOT_UNIQUE' => 'Inmatningen var ej unik.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Fältet `%1$s` har mottagit oväntad data. Orsak: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Inmatningen innehöll otillåtna tecken.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/tr/boardrules_acp.php b/language/tr/boardrules_acp.php index 13abd5ab..462cb4fd 100644 --- a/language/tr/boardrules_acp.php +++ b/language/tr/boardrules_acp.php @@ -112,6 +112,8 @@ 1 => '%d çakışan bağlantı çapası sayısal son eklerle yeniden adlandırıldı.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Seçilen dil yüklü değil.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Girdi illegal karakterler içeriyordu.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Girdi benzersiz değildi.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Boş bir kural kümesi yayınlanamaz veya taslak olarak değiştirilemez.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Bu dilin tüm kural kümesi yayınlansın mı? Bu dili kullananlar kural kümesini hemen görecek.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Bu dilin tüm kural kümesi taslak olarak değiştirilsin mi? Bu dili kullananlar bunun yerine forumun varsayılan dilindeki kuralları görecek.', diff --git a/language/tr/exceptions.php b/language/tr/exceptions.php deleted file mode 100644 index 61589149..00000000 --- a/language/tr/exceptions.php +++ /dev/null @@ -1,62 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Gerekli alan eksik', - 'EXCEPTION_INVALID_ARGUMENT' => '`%1$s` için geçersiz değişken belirtildi. Sebep: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => '`%1$s` alanı sınırın ötesinde bir veri aldı', - 'EXCEPTION_TOO_LONG' => 'Girdi, en fazla izin verilen uzunluğu aşıyordu.', - 'EXCEPTION_NOT_UNIQUE' => 'Girdi benzersiz değildi.', - 'EXCEPTION_UNEXPECTED_VALUE' => '`%1$s` alanı beklenmeyen veriler aldı. Sebep: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Girdi illegal karakterler içeriyordu.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/uk/boardrules_acp.php b/language/uk/boardrules_acp.php index 2e9d7ec8..1bae3784 100644 --- a/language/uk/boardrules_acp.php +++ b/language/uk/boardrules_acp.php @@ -119,6 +119,8 @@ 3 => '%d конфліктних якорів перейменовано з додаванням числових суфіксів.', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => 'Вибрану мову не встановлено.', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => 'Введений рядок містить некоректні символи.', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => 'Значення не унікальне.', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => 'Порожній набір правил не можна опублікувати або зробити чернеткою.', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => 'Опублікувати цей повний набір правил мови? Користувачі цієї мови побачать його негайно.', 'ACP_BOARDRULES_DRAFT_CONFIRM' => 'Зробити цей повний набір правил мови чернеткою? Користувачі цієї мови натомість побачать правила типовою мовою форуму.', diff --git a/language/uk/exceptions.php b/language/uk/exceptions.php deleted file mode 100644 index 61f5e9d9..00000000 --- a/language/uk/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => 'Обов’язкове поле незаповнене', - 'EXCEPTION_INVALID_ARGUMENT' => 'Некоректне значення у полі `%1$s`. Причина: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => 'В полі `%1$s` знаходиться значення, що виходить за допустимі рамки', - 'EXCEPTION_TOO_LONG' => 'Введений рядок довший за максимум.', - 'EXCEPTION_NOT_UNIQUE' => 'Значення не унікальне.', - 'EXCEPTION_UNEXPECTED_VALUE' => 'Некоректне значення у полі `%1$s`. Причина: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => 'Введений рядок містить некоректні символи.', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/language/zh_cmn_hans/boardrules_acp.php b/language/zh_cmn_hans/boardrules_acp.php index 1653b9c7..2c470cca 100644 --- a/language/zh_cmn_hans/boardrules_acp.php +++ b/language/zh_cmn_hans/boardrules_acp.php @@ -111,6 +111,8 @@ 1 => '%d 个冲突的锚点已使用数字后缀重命名。', ), 'ACP_BOARDRULES_INVALID_LANGUAGE' => '所选语言尚未安装。', + 'ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS' => '输入值含有非法字符。', + 'ACP_BOARDRULES_VALIDATION_NOT_UNIQUE' => '输入值不是唯一。', 'ACP_BOARDRULES_STATUS_CHANGE_EMPTY' => '空章程集不能发布或改为草稿。', 'ACP_BOARDRULES_PUBLISH_CONFIRM' => '发布此语言的完整章程集吗?使用此语言的用户将立即看到它。', 'ACP_BOARDRULES_DRAFT_CONFIRM' => '将此语言的完整章程集改为草稿吗?使用此语言的用户将改为看到论坛默认语言的章程。', diff --git a/language/zh_cmn_hans/exceptions.php b/language/zh_cmn_hans/exceptions.php deleted file mode 100644 index d679bafb..00000000 --- a/language/zh_cmn_hans/exceptions.php +++ /dev/null @@ -1,61 +0,0 @@ - -* @copyright (c) 2014 phpBB Limited -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -/** -* DO NOT CHANGE -*/ -if (!defined('IN_PHPBB')) -{ - exit; -} - -if (empty($lang) || !is_array($lang)) -{ - $lang = array(); -} - -// DEVELOPERS PLEASE NOTE -// -// All language files should use UTF-8 as their encoding and the files must not contain a BOM. -// -// Placeholders can now contain order information, e.g. instead of -// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows -// translators to re-order the output of data while ensuring it remains correct -// -// You do not need this where single placeholders are used, e.g. 'Message %d' is fine -// equally where a string contains only two placeholders which are used to wrap text -// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine -// -// Some characters you may want to copy&paste: -// ’ » “ ” … -// - -/* -* These are errors which can be triggered by sending invalid data to the -* boardrules extension API. -* -* These errors will never show to a user unless they are either modifying -* the core boardrules extension code OR unless they are writing an extension -* which makes calls to this extension. -* -* Translators: Feel free to not translate these language strings -*/ -$lang = array_merge($lang, array( - 'EXCEPTION_FIELD_MISSING' => '必填项缺失', - 'EXCEPTION_INVALID_ARGUMENT' => '`%1$s` 的参数无效。 原因: %2$s', - 'EXCEPTION_OUT_OF_BOUNDS' => '`%1$s` 字段收到的数据超出范围。', - 'EXCEPTION_TOO_LONG' => '输入值超过最大长度。', - 'EXCEPTION_NOT_UNIQUE' => '输入值不是唯一。', - 'EXCEPTION_UNEXPECTED_VALUE' => '`%1$s` 字段收到无效数据。原因: %2$s', - 'EXCEPTION_ILLEGAL_CHARACTERS' => '输入值含有非法字符。', - - // Translators: do not change this - 'EXCEPTION_WRONG_DATA_LANG' => $lang['WRONG_DATA_LANG'], -)); diff --git a/operators/rule.php b/operators/rule.php index cda7482b..649fda2c 100644 --- a/operators/rule.php +++ b/operators/rule.php @@ -57,7 +57,7 @@ public function __construct(ContainerInterface $container, \phpbb\boardrules\ope * @param int $parent_id Category to display rules from; default: 0 * @return \phpbb\boardrules\entity\rule_interface[] Rule entities * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function get_rules($language, $parent_id = 0) { @@ -88,8 +88,9 @@ public function get_rules($language, $parent_id = 0) * @return \phpbb\boardrules\entity\rule_interface Added rule entity * @access public * @throws \InvalidArgumentException If the language is not installed + * @throws \LogicException If the entity was already inserted * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function add_rule($entity, $language, $parent_id = 0) { @@ -100,9 +101,21 @@ public function add_rule($entity, $language, $parent_id = 0) try { - if ($parent_id && $this->get_rule_language($parent_id) !== (string) $language) + if ($parent_id) { - throw new \phpbb\boardrules\exception\out_of_bounds('new_parent_id'); + try + { + $parent_language = $this->get_rule_language($parent_id); + } + catch (\OutOfBoundsException $e) + { + throw new \OutOfBoundsException('RULE_PARENT_INVALID', 0, $e); + } + + if ($parent_language !== (string) $language) + { + throw new \OutOfBoundsException('RULE_PARENT_INVALID'); + } } // An empty ruleset must enter draft before its first rule is visible. @@ -141,7 +154,7 @@ public function add_rule($entity, $language, $parent_id = 0) * @return void * @access public * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function delete_rule($rule_id) { @@ -157,7 +170,7 @@ public function delete_rule($rule_id) } catch (\OutOfBoundsException $e) { - throw new \phpbb\boardrules\exception\out_of_bounds('rule_id'); + throw new \OutOfBoundsException('RULE_NOT_FOUND', 0, $e); } } @@ -170,7 +183,7 @@ public function delete_rule($rule_id) * @return bool True if the rule moved, false if it was already at the boundary * @access public * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function move($rule_id, $direction = 'up', $amount = 1) { @@ -188,7 +201,7 @@ public function move($rule_id, $direction = 'up', $amount = 1) } catch (\OutOfBoundsException $e) { - throw new \phpbb\boardrules\exception\out_of_bounds('rule_id'); + throw new \OutOfBoundsException('RULE_NOT_FOUND', 0, $e); } } @@ -200,31 +213,51 @@ public function move($rule_id, $direction = 'up', $amount = 1) * @return void * @access public * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function change_parent($rule_id, $new_parent_id) { $rule_id = (int) $rule_id; $new_parent_id = (int) $new_parent_id; - // Try to change rule parent try { $language = $this->get_rule_language($rule_id); - if ($new_parent_id && $this->get_rule_language($new_parent_id) !== $language) + } + catch (\OutOfBoundsException $e) + { + throw new \OutOfBoundsException('RULE_NOT_FOUND', 0, $e); + } + + if ($new_parent_id) + { + try { - throw new \OutOfBoundsException('RULES_NESTEDSET_INVALID_PARENT'); + $parent_language = $this->get_rule_language($new_parent_id); } + catch (\OutOfBoundsException $e) + { + throw new \OutOfBoundsException('RULE_PARENT_INVALID', 0, $e); + } + + if ($parent_language !== $language) + { + throw new \OutOfBoundsException('RULE_PARENT_INVALID'); + } + } + // Try to change rule parent + try + { $this->nestedset_rules ->use_language($language) ->change_parent($rule_id, $new_parent_id); } catch (\OutOfBoundsException $e) { - $field = (strpos($e->getMessage(), 'INVALID_ITEM') !== false) ? 'rule_id' : 'new_parent_id'; + $message = strpos($e->getMessage(), 'INVALID_ITEM') !== false ? 'RULE_NOT_FOUND' : 'RULE_PARENT_INVALID'; - throw new \phpbb\boardrules\exception\out_of_bounds($field); + throw new \OutOfBoundsException($message, 0, $e); } } @@ -233,7 +266,7 @@ public function change_parent($rule_id, $new_parent_id) * * @param int $rule_id Rule identifier * @return string Language ISO code - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ protected function get_rule_language($rule_id) { @@ -249,7 +282,7 @@ protected function get_rule_language($rule_id) * @param int $parent_id Category to display rules from * @return \phpbb\boardrules\entity\rule_interface[] Parent rule entities * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function get_rule_parents($language, $parent_id) { diff --git a/operators/rule_interface.php b/operators/rule_interface.php index ca99b540..60e3adbf 100644 --- a/operators/rule_interface.php +++ b/operators/rule_interface.php @@ -24,7 +24,7 @@ interface rule_interface * @param int $parent_id Category to display rules from; default: 0 * @return \phpbb\boardrules\entity\rule_interface[] Rule entities * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function get_rules($language, $parent_id = 0); @@ -37,8 +37,9 @@ public function get_rules($language, $parent_id = 0); * @return \phpbb\boardrules\entity\rule_interface Added rule entity * @access public * @throws \InvalidArgumentException If the language is not installed + * @throws \LogicException If the entity was already inserted * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds If the entity was already inserted + * @throws \OutOfBoundsException If the parent is invalid */ public function add_rule($entity, $language, $parent_id = 0); @@ -49,7 +50,7 @@ public function add_rule($entity, $language, $parent_id = 0); * @return void * @access public * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function delete_rule($rule_id); @@ -62,7 +63,7 @@ public function delete_rule($rule_id); * @return bool True if the rule moved, false if it was already at the boundary * @access public * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function move($rule_id, $direction, $amount = 1); @@ -74,7 +75,7 @@ public function move($rule_id, $direction, $amount = 1); * @return void * @access public * @throws \RuntimeException If the nested-set lock cannot be acquired - * @throws \phpbb\boardrules\exception\out_of_bounds + * @throws \OutOfBoundsException */ public function change_parent($rule_id, $new_parent_id); @@ -85,7 +86,7 @@ public function change_parent($rule_id, $new_parent_id); * @param int $parent_id Category to display rules from * @return \phpbb\boardrules\entity\rule_interface[] Parent rule entities * @access public - * @throws \phpbb\boardrules\exception\base If stored rule data is invalid + * @throws \InvalidArgumentException If stored rule data is invalid */ public function get_rule_parents($language, $parent_id); } diff --git a/tests/controller/admin_controller_test.php b/tests/controller/admin_controller_test.php index befa9033..efae2225 100644 --- a/tests/controller/admin_controller_test.php +++ b/tests/controller/admin_controller_test.php @@ -606,6 +606,18 @@ public function test_add_rule_collects_validation_errors(): void self::assertTrue($this->assigned_vars['S_ERROR']); self::assertStringContainsString('The submitted form was invalid. Try submitting again.', $this->assigned_vars['ERROR_MSG']); self::assertStringContainsString('ACP_RULE_TITLE_EMPTY', $this->assigned_vars['ERROR_MSG']); + self::assertStringContainsString('ACP_RULE_ANCHOR: ACP_BOARDRULES_VALIDATION_INVALID_CHARACTERS', $this->assigned_vars['ERROR_MSG']); + } + + public function test_add_rule_reports_friendly_title_validation(): void + { + $this->post['submit'] = true; + $this->variables['rule_title'] = str_repeat('a', 201); + + $this->controller->add_rule('fr'); + + self::assertTrue($this->assigned_vars['S_ERROR']); + self::assertStringContainsString('ACP_RULE_TITLE: The value you entered is too long.', $this->assigned_vars['ERROR_MSG']); } public function test_add_rule_submit_inserts_real_rule(): void @@ -635,7 +647,7 @@ public function test_edit_rule_initial_form_loads_real_entity(): void public function test_edit_rule_reports_missing_rule(): void { - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_ITEM'); $this->controller->edit_rule(999); } @@ -686,10 +698,10 @@ public function test_edit_rule_submit_saves_changes(): void public function test_edit_rule_reports_stale_entity_save(): void { $entity = $this->mock_entity(2); - $entity->method('save')->willThrowException(new \phpbb\boardrules\exception\out_of_bounds('rule_id')); + $entity->method('save')->willThrowException(new \LogicException('RULE_NOT_INSERTED')); $this->replace_controller_service('container', $this->entity_container($entity)); $this->post['submit'] = true; - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_ITEM'); $this->controller->edit_rule(2); } @@ -716,12 +728,12 @@ public function test_edit_rule_translates_parent_change_bounds_failure(): void $operator = $this->getMockBuilder(\phpbb\boardrules\operators\rule::class) ->disableOriginalConstructor() ->getMock(); - $operator->method('change_parent')->willThrowException(new \phpbb\boardrules\exception\out_of_bounds('new_parent_id')); + $operator->method('change_parent')->willThrowException(new \OutOfBoundsException('RULE_PARENT_INVALID')); $this->replace_controller_service('container', $this->entity_container($entity)); $this->replace_controller_service('rule_operator', $operator); $this->post['submit'] = true; $this->variables['rule_parent'] = 3; - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_PARENT'); $this->controller->edit_rule(2); } @@ -748,7 +760,7 @@ public function test_add_rule_reports_operator_errors($exception, $expected): vo public static function add_rule_operator_error_data(): array { return array( - 'entity bounds failure' => array(new \phpbb\boardrules\exception\out_of_bounds('rule_id'), 'EXCEPTION_OUT_OF_BOUNDS'), + 'entity bounds failure' => array(new \OutOfBoundsException('RULE_NOT_FOUND'), 'RULES_NESTEDSET_INVALID_ITEM'), 'nested-set lock failure' => array(new \RuntimeException('RULES_NESTEDSET_LOCK_FAILED_ACQUIRE'), 'RULES_NESTEDSET_LOCK_FAILED_ACQUIRE'), ); } @@ -765,7 +777,7 @@ public function test_delete_rule_requests_confirmation_and_redirects(): void public function test_delete_rule_reports_missing_rule(): void { - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_ITEM'); $this->controller->delete_rule(999); } @@ -793,9 +805,9 @@ public function test_delete_rule_translates_bounds_failure(): void $operator = $this->getMockBuilder(\phpbb\boardrules\operators\rule::class) ->disableOriginalConstructor() ->getMock(); - $operator->method('delete_rule')->willThrowException(new \phpbb\boardrules\exception\out_of_bounds('rule_id')); + $operator->method('delete_rule')->willThrowException(new \OutOfBoundsException('RULE_NOT_FOUND')); $this->replace_controller_service('rule_operator', $operator); - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_ITEM'); $this->controller->delete_rule(3); } @@ -820,14 +832,14 @@ public function test_move_rule_reports_rule_removed_after_move(): void $entity = $this->getMockBuilder(\phpbb\boardrules\entity\rule::class) ->disableOriginalConstructor() ->getMock(); - $entity->method('load')->willThrowException(new \phpbb\boardrules\exception\out_of_bounds('rule_id')); + $entity->method('load')->willThrowException(new \OutOfBoundsException('RULE_NOT_FOUND')); $operator = $this->getMockBuilder(\phpbb\boardrules\operators\rule::class) ->disableOriginalConstructor() ->getMock(); $operator->method('move')->willReturn(true); $this->replace_controller_service('container', $this->entity_container($entity)); $this->replace_controller_service('rule_operator', $operator); - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_ITEM'); $this->controller->move_rule(2, 'down'); } @@ -859,9 +871,9 @@ public function test_move_rule_translates_bounds_failure(): void $operator = $this->getMockBuilder(\phpbb\boardrules\operators\rule::class) ->disableOriginalConstructor() ->getMock(); - $operator->method('move')->willThrowException(new \phpbb\boardrules\exception\out_of_bounds('rule_id')); + $operator->method('move')->willThrowException(new \OutOfBoundsException('RULE_NOT_FOUND')); $this->replace_controller_service('rule_operator', $operator); - $this->setExpectedTriggerError(E_USER_WARNING, 'EXCEPTION_OUT_OF_BOUNDS'); + $this->setExpectedTriggerError(E_USER_WARNING, 'RULES_NESTEDSET_INVALID_ITEM'); $this->controller->move_rule(2, 'down'); } diff --git a/tests/entity/rule_entity_anchor_test.php b/tests/entity/rule_entity_anchor_test.php index 952c15ff..74eb026c 100644 --- a/tests/entity/rule_entity_anchor_test.php +++ b/tests/entity/rule_entity_anchor_test.php @@ -131,7 +131,7 @@ public function anchor_fails_test_data() */ public function test_anchor_fails($anchor) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\InvalidArgumentException::class); // Setup the entity class $entity = $this->get_rule_entity(); @@ -216,7 +216,7 @@ public function test_changed_legacy_anchor_is_validated() $entity = $this->get_rule_entity(); $entity->import($data); - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\InvalidArgumentException::class); $entity->set_anchor('another-❤'); } @@ -243,7 +243,7 @@ public function unique_anchor_test_fails_data() */ public function test_unique_anchor_fails($id, $language, $anchor) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\InvalidArgumentException::class); // Setup the entity class $entity = $this->get_rule_entity(); diff --git a/tests/entity/rule_entity_import_test.php b/tests/entity/rule_entity_import_test.php index 5b763c99..850468c4 100644 --- a/tests/entity/rule_entity_import_test.php +++ b/tests/entity/rule_entity_import_test.php @@ -149,7 +149,7 @@ public function import_test_fail_data() */ public function test_import_fail($data) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\InvalidArgumentException::class); // Setup the entity class $entity = $this->get_rule_entity(); @@ -157,4 +157,26 @@ public function test_import_fail($data) // Set the data $entity->import($data); } + + public function test_import_missing_field_uses_symbolic_message() + { + $data = $this->get_import_data()[1]; + unset($data['rule_title']); + + $this->expectException(\InvalidArgumentException::class); + $this->expectExceptionMessage('RULE_FIELD_MISSING:rule_title'); + + $this->get_rule_entity()->import($data); + } + + public function test_import_unsigned_field_uses_symbolic_message() + { + $data = $this->get_import_data()[1]; + $data['rule_message_bbcode_options'] = -1; + + $this->expectException(\InvalidArgumentException::class); + $this->expectExceptionMessage('RULE_FIELD_NOT_UNSIGNED:rule_message_bbcode_options'); + + $this->get_rule_entity()->import($data); + } } diff --git a/tests/entity/rule_entity_insert_test.php b/tests/entity/rule_entity_insert_test.php index d29a6fd9..da6458dc 100644 --- a/tests/entity/rule_entity_insert_test.php +++ b/tests/entity/rule_entity_insert_test.php @@ -51,7 +51,8 @@ public function test_insert() */ public function test_insert_fails() { - $this->expectException(\phpbb\boardrules\exception\out_of_bounds::class); + $this->expectException(\LogicException::class); + $this->expectExceptionMessage('RULE_ALREADY_INSERTED'); // Set a language variable $language = 'en'; diff --git a/tests/entity/rule_entity_language_test.php b/tests/entity/rule_entity_language_test.php index c9493f0b..35db282f 100644 --- a/tests/entity/rule_entity_language_test.php +++ b/tests/entity/rule_entity_language_test.php @@ -78,7 +78,8 @@ public function test_set_language($data, $language) // Assert that the anchor matches what's expected if ($language !== 'en') { - $this->expectException('\phpbb\boardrules\exception\unexpected_value'); + $this->expectException(\InvalidArgumentException::class); + $this->expectExceptionMessage('ACP_BOARDRULES_INVALID_LANGUAGE'); } // Set the anchor diff --git a/tests/entity/rule_entity_load_test.php b/tests/entity/rule_entity_load_test.php index 84fe4d8d..74f4ba12 100644 --- a/tests/entity/rule_entity_load_test.php +++ b/tests/entity/rule_entity_load_test.php @@ -123,7 +123,8 @@ public function load_fails_test_data() */ public function test_load_fails($id) { - $this->expectException(\phpbb\boardrules\exception\out_of_bounds::class); + $this->expectException(\OutOfBoundsException::class); + $this->expectExceptionMessage('RULE_NOT_FOUND'); // Setup the entity class $entity = $this->get_rule_entity(); diff --git a/tests/entity/rule_entity_save_test.php b/tests/entity/rule_entity_save_test.php index 2322f7b5..4b732fc8 100644 --- a/tests/entity/rule_entity_save_test.php +++ b/tests/entity/rule_entity_save_test.php @@ -106,7 +106,8 @@ public function test_four_byte_title_characters_are_encoded_and_other_unicode_is */ public function test_save_fails() { - $this->expectException(\phpbb\boardrules\exception\out_of_bounds::class); + $this->expectException(\LogicException::class); + $this->expectExceptionMessage('RULE_NOT_INSERTED'); // Setup the entity class $entity = $this->get_rule_entity(); diff --git a/tests/entity/rule_entity_title_test.php b/tests/entity/rule_entity_title_test.php index 046a52f9..fc530fc9 100644 --- a/tests/entity/rule_entity_title_test.php +++ b/tests/entity/rule_entity_title_test.php @@ -93,7 +93,7 @@ public function title_fails_test_data() */ public function test_title_fails($title) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\InvalidArgumentException::class); // Setup the entity class $entity = $this->get_rule_entity(); diff --git a/tests/operators/rule_operator_add_rule_test.php b/tests/operators/rule_operator_add_rule_test.php index 41857d33..4e995ede 100644 --- a/tests/operators/rule_operator_add_rule_test.php +++ b/tests/operators/rule_operator_add_rule_test.php @@ -86,9 +86,9 @@ public function test_add_rule_rejects_parent_from_another_language() $this->get_rule_operator()->add_rule($entity, 'en', $german_parent_id); self::fail('A parent from another language should be rejected.'); } - catch (\phpbb\boardrules\exception\out_of_bounds $e) + catch (\OutOfBoundsException $e) { - self::assertSame('new_parent_id', $e->getMessage()); + self::assertSame('RULE_PARENT_INVALID', $e->getMessage()); } self::assertSame('0', (string) $this->config['nestedset_rules_lock']); diff --git a/tests/operators/rule_operator_change_parent_test.php b/tests/operators/rule_operator_change_parent_test.php index a837d815..48640183 100644 --- a/tests/operators/rule_operator_change_parent_test.php +++ b/tests/operators/rule_operator_change_parent_test.php @@ -30,7 +30,8 @@ public function test_change_parent_rejects_another_language() $this->db->sql_query($sql); $german_rule_id = (int) $this->db->sql_nextid(); - $this->expectException(\phpbb\boardrules\exception\out_of_bounds::class); + $this->expectException(\OutOfBoundsException::class); + $this->expectExceptionMessage('RULE_PARENT_INVALID'); $this->get_rule_operator()->change_parent(1, $german_rule_id); } @@ -106,9 +107,9 @@ public function test_change_parent($rule_id, $new_parent_id, $expected) public function change_parent_fails_data() { return array( - array(1, 100), - array(100, 1), - array(null, 1), + array(1, 100, 'RULE_PARENT_INVALID'), + array(100, 1, 'RULE_NOT_FOUND'), + array(null, 1, 'RULE_NOT_FOUND'), ); } @@ -117,9 +118,10 @@ public function change_parent_fails_data() * * @dataProvider change_parent_fails_data */ - public function test_change_parent_fails($rule_id, $new_parent_id) + public function test_change_parent_fails($rule_id, $new_parent_id, $message) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\OutOfBoundsException::class); + $this->expectExceptionMessage($message); // Setup the operator class $operator = $this->get_rule_operator(); diff --git a/tests/operators/rule_operator_delete_rule_test.php b/tests/operators/rule_operator_delete_rule_test.php index c3711358..1d9463ae 100644 --- a/tests/operators/rule_operator_delete_rule_test.php +++ b/tests/operators/rule_operator_delete_rule_test.php @@ -106,7 +106,8 @@ public function delete_rule_fails_data() */ public function test_delete_rules_fails($rule_id) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\OutOfBoundsException::class); + $this->expectExceptionMessage('RULE_NOT_FOUND'); // Setup the operator class $operator = $this->get_rule_operator(); diff --git a/tests/operators/rule_operator_move_test.php b/tests/operators/rule_operator_move_test.php index a0523fe6..9668206f 100644 --- a/tests/operators/rule_operator_move_test.php +++ b/tests/operators/rule_operator_move_test.php @@ -218,7 +218,8 @@ public function move_rules_fails_data() */ public function test_move_rules_fails($rule_id) { - $this->expectException(\phpbb\boardrules\exception\base::class); + $this->expectException(\OutOfBoundsException::class); + $this->expectExceptionMessage('RULE_NOT_FOUND'); // Setup the operator class $operator = $this->get_rule_operator(); diff --git a/tests/system/exception_test.php b/tests/system/exception_test.php deleted file mode 100644 index 25b360d1..00000000 --- a/tests/system/exception_test.php +++ /dev/null @@ -1,120 +0,0 @@ - -* @license GNU General Public License, version 2 (GPL-2.0) -* -*/ - -namespace phpbb\boardrules\tests\system; - -class exception_test extends \phpbb_test_case -{ - /** @var \phpbb\language\language */ - protected $lang; - - /** - * Get an instance of \phpbb\language\language - */ - public function get_language_instance() - { - global $phpbb_root_path, $phpEx; - - // Get instance of \phpbb\language\language (dataProvider is called before setUp(), so this must be done here) - $lang_loader = new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx); - $lang_loader->set_extension_manager(new \phpbb_mock_extension_manager($phpbb_root_path)); - $this->lang = new \phpbb\language\language($lang_loader); - $this->lang->add_lang('exceptions', 'phpbb/boardrules'); - } - - protected function setUp(): void - { - parent::setUp(); - - $this->get_language_instance(); - } - - /** - * Data for test_exceptions function - * - * @return array - */ - public function exceptions_test_data() - { - $this->get_language_instance(); - - return array( - array( - 'base', - 'EXCEPTION_FIELD_MISSING', - $this->lang->lang('EXCEPTION_FIELD_MISSING'), - ), - array( - 'base', - array('EXCEPTION_OUT_OF_BOUNDS', '{foo}'), - $this->lang->lang('EXCEPTION_OUT_OF_BOUNDS', '{foo}'), - ), - array( - 'invalid_argument', - array('{foo}', 'FIELD_MISSING'), - $this->lang->lang('EXCEPTION_INVALID_ARGUMENT', '{foo}', $this->lang->lang('EXCEPTION_FIELD_MISSING')), - ), - array( - 'out_of_bounds', - '{foo}', - $this->lang->lang('EXCEPTION_OUT_OF_BOUNDS', '{foo}'), - ), - array( - 'unexpected_value', - array('{foo}', 'TOO_LONG'), - $this->lang->lang('EXCEPTION_UNEXPECTED_VALUE', '{foo}', $this->lang->lang('EXCEPTION_TOO_LONG')), - ), - ); - } - - /** - * Test some exceptions and make sure they're translated - * - * @dataProvider exceptions_test_data - */ - public function test_exceptions($exception_name, $message, $expected) - { - try - { - $exception_name = '\phpbb\boardrules\exception\\' . $exception_name; - - throw new $exception_name($message); - } - catch (\phpbb\boardrules\exception\base $e) - { - self::assertEquals($expected, $e->get_message($this->lang)); - } - } - - /** - * Test exception language file is being loaded - */ - public function test_exceptions_lang() - { - self::assertEquals('Required field missing', $this->lang->lang('EXCEPTION_FIELD_MISSING')); - } - - public static function exception_string_data(): array - { - return array( - 'scalar message' => array('plain message', 'plain message'), - 'array message' => array(array('KEY', 'argument'), "array (\n 0 => 'KEY',\n 1 => 'argument',\n)"), - 'null message' => array(null, ''), - ); - } - - /** - * @dataProvider exception_string_data - */ - public function test_exception_string_representation($message, $expected): void - { - self::assertSame($expected, (string) new \phpbb\boardrules\exception\base($message)); - } -}