Cleaning up query provider.