code documentation (database layer & minor fixes)
removed debugging message in controller module