Fixing Database Class