Skip to content

Commit

Permalink
fix: mark inputs of styling plugin as required
Browse files Browse the repository at this point in the history
While this cannot ensure that the value is valid, it should prevent
accidental saving of an empty field, which crashes the less compiler.

Fixes #2246
  • Loading branch information
micgro42 committed Apr 6, 2018
1 parent fcbc613 commit 76d5dac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/plugins/styling/admin.php
Expand Up @@ -83,7 +83,7 @@ public function form() {

echo '<tr>';
echo '<td><label for="tpl__'.hsc($key).'">'.$name.'</label></td>';
echo '<td><input type="text" name="tpl['.hsc($key).']" id="tpl__'.hsc($key).'" value="'.hsc($value).'" '.$this->colorClass($key).' dir="ltr" /></td>';
echo '<td><input type="text" name="tpl['.hsc($key).']" id="tpl__'.hsc($key).'" value="'.hsc($value).'" '.$this->colorClass($key).' dir="ltr" required/></td>';
echo '</tr>';
}
echo '</tbody></table>';
Expand Down

0 comments on commit 76d5dac

Please sign in to comment.