瀏覽代碼

Specify radix for parseInt

JC Brand 8 年之前
父節點
當前提交
40605607e6
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/converse-core.js

+ 1 - 1
src/converse-core.js

@@ -859,7 +859,7 @@
                 var resources = this.get('resources');
                 if (!_.isObject(resources)) { resources = {}; }
                 resources[resource] = {
-                    'priority': _.isNaN(parseInt(priority)) ? 0 : parseInt(priority),
+                    'priority': _.isNaN(parseInt(priority, 10)) ? 0 : parseInt(priority, 10),
                     'status': chat_status,
                     'timestamp': moment().format()
                 };