Skip to content

Commit 13fa06e

Browse files
committed
BUG: Fix bug in moi.init
The position of the group_id argument was moved and the rest of the code was not updated to reflect this. This change set moves group_id so it is the first argument.
1 parent 33e5404 commit 13fa06e

File tree

1 file changed

+3
-3
lines changed
  • qiita_pet/static/vendor/js

1 file changed

+3
-3
lines changed

qiita_pet/static/vendor/js/moi.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,15 +66,15 @@ var moi = new function () {
6666
* websocket. On construction, this method will send a message over the
6767
* socket to get all known job information associated with this client.
6868
*
69-
* @param {host} The URL for the websocket, minus the ws:// header, or null
70-
* to use the default moi-ws.
7169
* @param {group_id} A group ID to get initial data from, or null to fetch
7270
* all records associated with the user.
71+
* @param {host} The URL for the websocket, minus the ws:// header, or null
72+
* to use the default moi-ws.
7373
* @param {on_open} Optional function for action when websocket is opened.
7474
* @param {on_close} Optional function for action when websocket is closed.
7575
* @param {on_error} Optional function for action when websocket errors.
7676
*/
77-
this.init = function(host, group_id, on_open, on_close, on_error) {
77+
this.init = function(group_id, host, on_open, on_close, on_error) {
7878
host = host || window.location.host + '/moi-ws/';
7979
if (!("WebSocket" in window)) {
8080
alert("Your browser does not appear to support websockets!");

0 commit comments

Comments
 (0)