Refactoring database classes
Added init in Controller