[database] fix redis' get on undefined id