Better to assert the preconditions at the top of the function; this function makes no sense without callback, it does nothing other than iterate over the database and call the callbacks for relevant entries!