Skip to content
This repository has been archived by the owner on Jun 28, 2022. It is now read-only.

Commit

Permalink
Fix rename bug
Browse files Browse the repository at this point in the history
  • Loading branch information
benb116 committed Jul 20, 2015
1 parent 0634b24 commit eb2f725
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions public/js/main.js
Expand Up @@ -221,7 +221,7 @@ function SchedTriggers() {
// {break}
schedRename = prompt('Please enter a unique name for your new schedule.');
}
if (schedName !== '' && schedName !== null) {
if (schedRename !== '' && schedRename !== null && schedRename != 'null') {
schedURL = "/Sched?addRem=ren&courseID=blank&schedName="+schedName+"&schedRename="+schedRename; // Make the request
SendReq(schedURL, ListScheds, -2);
}
Expand Down Expand Up @@ -540,7 +540,11 @@ function StarFormat(sections) { // Format starred section list
'<span>'+sections[0][section].SectionName + sections[0][section].TimeInfo+'</span>'+
'<i class="'+starClass+'"></i></li>';
}}
$('#CourseTitle').html('Starred Sections');
if (sections[0]) {
$('#CourseTitle').html('Starred Sections');
} else {
$('#CourseTitle').html('No Starred Sections');
}
$('#SectionList > ul').append(HTML); // Put the course number list in #SectionList
for (var sec in sections[0]) {
RetrievePCR(sections[0][sec].SectionName);
Expand Down

0 comments on commit eb2f725

Please sign in to comment.