Fix the check for whether a metadata filter was provided or not