updated database and bug fixes