We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running a custom script from command line; we get the following error:
Fatal error: Uncaught Error: Call to a member function translatePlural() on null in /var/www/glpi/inc/autoload.function.php:171 Stack trace: #0 /var/www/glpi/inc/notepad.class.php(171): _n('Note', 'Notes', 2) #1 /var/www/glpi/inc/computer.class.php(881): Notepad::getSearchOptionsToAdd() #2 /var/www/glpi/inc/search.class.php(5382): Computer->getSearchOptions() #3 /var/www/glpi/inc/log.class.php(124): Search::getOptions('Computer') #4 /var/www/glpi/inc/commondbtm.class.php(381): Log::constructHistory(Object(Infocom), Array, Array) #5 /var/www/glpi/inc/commondbtm.class.php(1146): CommonDBTM->updateInDB(Array, Array) #6 /path/to/scrpit.php(1234): CommonDBTM->update(Array) #7 {main} thrown in /var/www/glpi/inc/autoload.function.php on line 171
Problem is $TRANSLATION variable is only set once logged in. There is a fallback for the __() method, but not for _n().
$TRANSLATION
__()
_n()
The text was updated successfully, but these errors were encountered:
Prevent plural translations errors when not logged in; fixes glpi-pro…
e885ffe
…ject#2949
Prevent plural translations errors when not logged in; fixes #2949
6093725
890d749
a48af9a
trasher
No branches or pull requests
Running a custom script from command line; we get the following error:
Problem is
$TRANSLATION
variable is only set once logged in. There is a fallback for the__()
method, but not for_n()
.The text was updated successfully, but these errors were encountered: