1. Wez Furlong
  2. mtrack

Commits

Wez Furlong  committed c7918d1

don't allow empty snippets

  • Participants
  • Parent commits e977918
  • Branches default

Comments (0)

Files changed (1)

File inc/snippet.php

View file
   {
     $this->updated = $CS->cid;
 
+    if (!strlen(trim($this->snippet))) {
+      throw new Exception("Snippet cannot be empty");
+    }
+
     if ($this->snid === null) {
       $this->created = $CS->cid;