OnePlc / PLC_X_Translation

Manage translations for your entities in oneplace
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Error when compiling language files #1

Open Praesidiarius opened 4 years ago

Praesidiarius commented 4 years ago

Bug Report

Q A
Version(s) 1.0.2

Summary

After saving a translation (when the language files are generated) there is an php error

Warning: fread(): Length parameter must be greater than 0 in /var/www/plc/vendor/laminas/laminas-i18n/src/Translator/Loader/Gettext.php on line 185

Current behavior

PHP error because of corrupt .mo files

How to reproduce

Add a translation and save it

Expected behavior

should work fine

Praesidiarius commented 4 years ago

error comes only when you have only translations for 1 language. it think its because we always generate de_DE files. Change it to only generate the language files where translations are found