This commit is contained in:
calzoneman 2013-05-12 21:37:03 -04:00
parent c7e63391f6
commit a6fff1c849
6 changed files with 24 additions and 6 deletions

View File

@ -56,7 +56,7 @@ exports.register = function(name, pw) {
return false;
}
var hash = bcrypt.hashSync(pw, 10);
var query = "INSERT INTO registrations VALUES (NULL, '{1}', '{2}', 1, '', 0)"
var query = "INSERT INTO registrations VALUES (NULL, '{1}', '{2}', 1, '', 0, '', '')"
.replace(/\{1\}/, name)
.replace(/\{2\}/, hash);
var results = db.querySync(query);

View File

@ -2,7 +2,7 @@
"author": "Calvin Montgomery",
"name": "CyTube",
"description": "Online media synchronizer and chat",
"version": "1.7.0",
"version": "1.7.1",
"repository": {
"url": "http://github.com/calzoneman/sync"
},

View File

@ -9,7 +9,7 @@ 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.7.0";
const VERSION = "1.7.1";
var fs = require("fs");
var Logger = require("./logger.js");

View File

@ -29,7 +29,7 @@ Callbacks = {
announcement: function(data) {
var div = $("<div/>").addClass("alert")
.insertAfter($(".row")[0]);
$("<button/>").addClass("close pull-right").data.text("×")
$("<button/>").addClass("close pull-right").text("×")
.appendTo(div)
.click(function() { div.remove(); });
$("<h3/>").data.text(data.title).appendTo(div);

View File

@ -806,7 +806,7 @@ function showLoginFrame() {
}
function showUserOpts() {
var vid = $("#ytapiplayer").detach();
PLAYER.hide();
var modal = $("<div/>").addClass("modal hide fade")
.appendTo($("body"));
var head = $("<div/>").addClass("modal-header")
@ -932,7 +932,7 @@ function showUserOpts() {
});
modal.on("hidden", function() {
vid.appendTo($("#videodiv"));
PLAYER.unhide();
applyOpts();
modal.remove();
});

View File

@ -349,3 +349,21 @@ Media.prototype.removeOld = function() {
old.remove();
placeholder.attr("id", "ytapiplayer");
}
Media.prototype.hide = function() {
this.getTime(function(seconds) {
this.time = seconds;
this.hidden = $("#ytapiplayer").detach();
}.bind(this));
}
Media.prototype.unhide = function() {
this.hidden.appendTo($("#videodiv"));
var data = {
id: this.id,
currentTime: this.time
};
setTimeout(function() { this.load(data); }.bind(this), 1000);
delete this.hidden;
delete this.time;
}