Bugfix: Prevent Modx.console callback accumulating

Previously, if you'd run modx.console X times,  the onMessage callback would be called X times, instead of only once. Resolved by changing from anonymous JS function to named one.