Your underlying assumption is incorrect - Part 107 is not, by definition, just commercial. You should read the law before making such broad and incorrect statements. You could start with Part 107 itself, specifically 107.1. Part 107 covers all civil sUAS operations in the US and, while you can claim the Part 101 exemption from it for purely recreational flight, you are not required to do that. You could also run the
FAA user identification tool, which will tell you that recreational flight is fine under Part 107.
Beyond that, it's not your responsibility to prove that you are flying recreationally, and so unless the ranger had a (valid) reason to believe that the operation was commercial then he had no business issuing a citation.