Added my previous patch from a couple of moinths ago.