Added logging for db null pointers