[#3022][#3258] Tweaks thanks to @cordoval