Skip to content

Commit f53ace5

Browse files
committed
Fixes #85 where online class times would not get returned or rendered.
1 parent 348b052 commit f53ace5

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

assets/src/modules/sm/Schedule/directives/scheduleDirective.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,9 +169,9 @@ angular.module('sm').directive('schedule', function($timeout, $filter) {
169169
for(var coursesIndex = 0, coursesLength = this.scope.schedule.length; coursesIndex < coursesLength; coursesIndex++) {
170170
var course = this.scope.schedule[coursesIndex];
171171
this.courseDrawIndex++;
172-
if(course.online) {
172+
if(course.online && !course.hasOwnProperty('times')) {
173173
this.scope.onlineCourses.push(course);
174-
} else if(course.times != undefined) {
174+
} else if(course.hasOwnProperty('times')) {
175175
this.drawCourse(course);
176176
}
177177
//console.log(course);

inc/databaseConn.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,6 @@ function getMeetingInfo($sectionData) {
5252
$course['description'] = $sectionData['description'];
5353
}
5454

55-
// If the course is online, then don't even bother looking for it's times
56-
if($course['online']) { return $course; }
57-
5855
// Now we query for the times of the section
5956
$query = "SELECT b.code, b.number, b.off_campus, t.room, t.day, t.start, t.end ";
6057
$query .= "FROM times AS t JOIN buildings AS b ON b.number=t.building ";

0 commit comments

Comments
 (0)