moved db access to here
removed db access from here
return value in getAll method