From 307699119af2337a30213969032ab96aa3401b51 Mon Sep 17 00:00:00 2001
From: jrfnl <jrfnl@users.noreply.github.com>
Date: Fri, 12 Jul 2019 06:12:47 +0200
Subject: [PATCH] Simplify & modernize functions in
tools/i18n/not-gettexted.php
---
tools/i18n/not-gettexted.php | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/tools/i18n/not-gettexted.php b/tools/i18n/not-gettexted.php
index e8ae2c3143..c40631b6ea 100644
|
a
|
b
|
class NotGettexted { |
| 29 | 29 | var $commands = array('extract' => 'command_extract', 'replace' => 'command_replace' ); |
| 30 | 30 | |
| 31 | 31 | |
| 32 | | function logmsg() { |
| 33 | | $args = func_get_args(); |
| | 32 | function logmsg( ...$args ) { |
| 34 | 33 | if ($this->enable_logging) error_log(implode(' ', $args)); |
| 35 | 34 | } |
| 36 | 35 | |
| … |
… |
class NotGettexted { |
| 138 | 137 | } |
| 139 | 138 | |
| 140 | 139 | |
| 141 | | function command_extract() { |
| 142 | | $args = func_get_args(); |
| | 140 | function command_extract( ...$args ) { |
| 143 | 141 | $pot_filename = $args[0]; |
| 144 | 142 | if (isset($args[1]) && is_array($args[1])) |
| 145 | 143 | $filenames = $args[1]; |
| … |
… |
class NotGettexted { |
| 176 | 174 | return true; |
| 177 | 175 | } |
| 178 | 176 | |
| 179 | | function command_replace() { |
| 180 | | $args = func_get_args(); |
| | 177 | function command_replace( ...$args ) { |
| 181 | 178 | $mo_filename = $args[0]; |
| 182 | 179 | if (isset($args[1]) && is_array($args[1])) |
| 183 | 180 | $filenames = $args[1]; |