Allow registration of custom error and success messages, closes #33