BUGFIX: Fixed issues that came with better if statements.
ADDED: tested indexed database API