Implementing db hook as func. need to assert reference as value