fixed an issue where queue items persisted in database due to wrong revision data being passed to database.remove - database API for write now returns revision as first parameter in callback