Fix Issue#23

This commit is contained in:
calzoneman 2013-04-04 11:05:01 -05:00
parent 11f1ab60f9
commit f7bc601fed
3 changed files with 7 additions and 3 deletions

View file

@ -783,6 +783,9 @@ Channel.prototype.tryVote = function(user, data) {
}
Channel.prototype.tryVoteskip = function(user) {
if(!this.opts.allow_voteskip) {
return;
}
if(!this.voteskip) {
this.voteskip = new Poll("voteskip", "voteskip", ["yes"]);
}

View file

@ -9,11 +9,11 @@ The above copyright notice and this permission notice shall be included in all c
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
const VERSION = "1.0.0";
console.log("Starting CyTube v" + VERSION);
const VERSION = "1.0.1";
var fs = require("fs");
var Logger = require("./logger.js");
Logger.syslog.log("Starting CyTube v" + VERSION);
var Config = require("./config.js");
var connect = require("connect");
var app = connect.createServer(connect.static(__dirname+"/www")).listen(Config.IO_PORT);

View file

@ -236,7 +236,8 @@ function initCallbacks() {
var linew = $("#queue").children()[data.idx];
$(linew).addClass("alert alert-info");
POSITION = data.idx;
$("#voteskip").attr("disabled", false);
if(CHANNELOPTS.allow_voteskip)
$("#voteskip").attr("disabled", false);
});
socket.on("mediaUpdate", function(data) {