(PUP-2902) Change error message when attempting to collect classes.

An attempt to collect classes led to an error message that said
that 'class' is not a known resource type (in a way that can be
misinterpreted).

This commit make the error message specific, and clear.
Merge pull request #2847 from hlindberg/PUP-2902_collect-class-is-error

(PUP-2902) Change error message when attempting to collect classes.