Refs #482: CasperError should be declared as a global function