Ensure resource generates correct route definiton

Also lose the blank object in empty class definitions
Ignore tmp*