Fixed use of undefined exception
Merge pull request #1100 from esc24/commanderrfix

Fixed use of undefined exception