Applied some fixes to implementation of ticket #588
Authored by: numere 2021-06-12
Parent: [r885]
Child: [r887]