Don't check for class existence if we're not sending to a class.

(imported from commit 832de3f899d90ee727cebeede061de6a409b7845)
This commit is contained in:
Luke Faraone 2012-09-06 15:19:56 -04:00
parent ebfb696ff7
commit 3d1e956069
1 changed files with 4 additions and 0 deletions

View File

@ -62,6 +62,10 @@ $(function() {
.stop(true).fadeTo(0,1);
buttons.attr('disabled', 'disabled');
buttons.blur()
if ($("#class-message:visible")[0] == undefined) {// we're not dealing with classes
return true;
}
var okay = true;
$.ajaxSetup({async:false}); // so we get blocking gets
$.get("subscriptions/exists/" + $("#class").val(), function(data) {