mirror of
https://github.com/zulip/zulip.git
synced 2025-11-04 22:13:26 +00:00
avatar.set_up_file_input returns object now
The set_up_file_input() function now returns an object to the user with a clear field. This object will grow soon. (imported from commit 7b3761eafddb392bd2c84a1685aa8d1811028a0f)
This commit is contained in:
@@ -105,7 +105,11 @@ exports.set_up_file_input = function (
|
|||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
});
|
});
|
||||||
|
|
||||||
return clear;
|
return {
|
||||||
|
// Call back to clear() in situations like adding bots, when
|
||||||
|
// we want to use the same widget over and over again.
|
||||||
|
clear: clear
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
return exports;
|
return exports;
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ $(function () {
|
|||||||
"Please only use characters that are valid in an email address");
|
"Please only use characters that are valid in an email address");
|
||||||
|
|
||||||
|
|
||||||
var clear_bot_avatar_file_input = avatar.set_up_avatar_logic_for_creating_bots();
|
var clear_bot_avatar_file_input = avatar.set_up_avatar_logic_for_creating_bots().clear;
|
||||||
|
|
||||||
$('#create_bot_form').validate({
|
$('#create_bot_form').validate({
|
||||||
errorClass: 'text-error',
|
errorClass: 'text-error',
|
||||||
|
|||||||
Reference in New Issue
Block a user