Fix bug in FOFEncryptTotp::checkCode (Backported from f0f)

WIth permission from Nic