Cleanup, don't call .captures on nilobject
Allow querying by entity and check