If clause was wrong for keychain