Clean up query method invocation.