]> git.treefish.org Git - banana.git/blobdiff - admin/blackboard.php
added next session to summary.
[banana.git] / admin / blackboard.php
index b683221cf84298dcb8426dcc9030c49157004f24..139abe9309a030a914fa27a611d1f0704a710467 100644 (file)
@@ -8,6 +8,11 @@
     block("lightgreen", "added blackboard");
   }
 
     block("lightgreen", "added blackboard");
   }
 
+  if ($db->query("SELECT COUNT(*) FROM students")->fetch(PDO::FETCH_NUM)[0] == 0) {
+    block("red", "no students registered");
+    exit;
+  }
+
   block("black", "add blackboard");
 ?>
 
   block("black", "add blackboard");
 ?>