Updated Database class to use try/catch instead of failing silently