From 2fe034d161f1bd4c71b1c519050dfcfb61becf6d Mon Sep 17 00:00:00 2001 From: Keegan McAllister Date: Thu, 18 Oct 2012 16:25:58 -0400 Subject: [PATCH] Rename subs.add -> subs.add_for_send This has some logic specific to the "Create and send" / "Subscribe and send" buttons. (imported from commit 5f9e314ebde31ec1e6a183513816d1ade361e4cc) --- zephyr/static/js/subs.js | 2 +- zephyr/static/js/ui.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/zephyr/static/js/subs.js b/zephyr/static/js/subs.js index 892d9235f9..bf61f524c3 100644 --- a/zephyr/static/js/subs.js +++ b/zephyr/static/js/subs.js @@ -52,7 +52,7 @@ exports.fetch = function () { }); }; -exports.add = function (stream, prompt_button) { +exports.add_for_send = function (stream, prompt_button) { $.ajax({ type: 'POST', url: '/json/subscriptions/add', diff --git a/zephyr/static/js/ui.js b/zephyr/static/js/ui.js index 1dcbbd38df..a90dd9e37a 100644 --- a/zephyr/static/js/ui.js +++ b/zephyr/static/js/ui.js @@ -255,12 +255,12 @@ $(function () { // Prepare the click handler for subbing to a new stream to which // you have composed a message. $('#create-it').click(function () { - subs.add(compose.stream_name(), $('#stream-dne')); + subs.add_for_send(compose.stream_name(), $('#stream-dne')); }); // Prepare the click handler for subbing to an existing stream. $('#sub-it').click(function () { - subs.add(compose.stream_name(), $('#stream-nosub')); + subs.add_for_send(compose.stream_name(), $('#stream-nosub')); }); var throttled_scrollhandler = $.throttle(50, function(e) {