fix(db): query cache properly handles more callable types

This isn't absolutely necessary but logs are chaotic as is