diff --git a/src/messenger/webim/js/source/chat/model_views/leave_message/leave_message_form.js b/src/messenger/webim/js/source/chat/model_views/leave_message/leave_message_form.js index 4fac1a57..08fb6214 100644 --- a/src/messenger/webim/js/source/chat/model_views/leave_message/leave_message_form.js +++ b/src/messenger/webim/js/source/chat/model_views/leave_message/leave_message_form.js @@ -92,6 +92,14 @@ this.model.submit(); }, + /** + * Handler function for model 'submitError' event. + * Update captcha img if captcha field has wrong value. + * + * @param {Mibew.Models.LeaveMessageForm} model Form model + * @param {Object} error Error object, contains 'code' and 'message' + * fields + */ submitError: function(model, error) { if (error.code == model.ERROR_WRONG_CAPTCHA && model.get('showCaptcha')) { var src = this.ui.captchaImg.attr('src');