Set __call directly in class definition
Fix some issues in db.lua