Removing a magic value in favor of a variable

Kevin Kremer kkmailinglists at gmail.com
Wed Mar 4 19:36:36 CET 2020


Thanks!

I added $config['kolab_tags_per_folder'] = 100 to /etc/roundcube/config.inc.php and it works for my installation. For the PR, I created a new file plugins/kolab_tags/config.inc.php.dist where the variable defaults to 100, but I am not sure if this is enough. Where is the best place to put the new variable so I do not break any other installation with my PR?

Best,
Kevin

On  4 March 2020 18:15, Aleksander Machniak <machniak at kolabsys.com> wrote:

>On 04.03.2020 17:42, Kevin Kremer wrote:
>> Hi all,
>> 
>> I just ran into a problem with a magic value at plugins/kolab_tags/lib/kolab_tags_backend.php:48
>> When creating more than 100 tags per folder they just disappear from the webinterface (even though they are created successfully on the server). While changing the magic value fixed the problem for me, I'd like to create a PR that changes the magic value to a variable (e.g. $config['kolab_tags_per_folder'] = 100). Unfortunately, I failed to access the global configuration from class kolab_tags_backend. Other plugins use something like $this->rc->config->get('config_name').
>
>rcube::get_instance()->config->get('config_name');
>
>-- 
>Aleksander Machniak
>Senior Software Engineer
>Kolab Systems AG: https://kolabsystems.com
>PGP: 19359DC1
>_______________________________________________
>users mailing list
>users at lists.kolab.org
>https://lists.kolab.org/mailman/listinfo/users


More information about the users mailing list