diff options
author | Joey Hess <joey@kodama.kitenet.net> | 2008-07-13 15:05:34 -0400 |
---|---|---|
committer | Joey Hess <joey@kodama.kitenet.net> | 2008-07-13 15:05:34 -0400 |
commit | ffc99f5904934e6e7532bb8cfdebb44ad9ecd913 (patch) | |
tree | ec5d4d68b68c4fbbd77d33b51e59056ec011bc80 /doc/plugins | |
parent | edb59cd5b949de7a68f3b74e7949bf3893b23c6a (diff) |
switch preprocess hooks to use error function
Diffstat (limited to 'doc/plugins')
-rw-r--r-- | doc/plugins/write/tutorial.mdwn | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/plugins/write/tutorial.mdwn b/doc/plugins/write/tutorial.mdwn index 8b12fd183..94b72c763 100644 --- a/doc/plugins/write/tutorial.mdwn +++ b/doc/plugins/write/tutorial.mdwn @@ -169,7 +169,7 @@ be a guard on how high it will go. } my $num=$last{$page}++; if ($num > 25) { - return "[[fib will only calculate the first 25 numbers in the sequence]]"; + error "can only calculate the first 25 numbers in the sequence"; } return fib($num); } @@ -182,7 +182,7 @@ does for numbers less than 1. Or for any number that's not an integer. In either case, it will run forever. Here's one way to fix that: if (int($num) != $num || $num < 1) { - return "[[fib positive integers only, please]]"; + error "positive integers only, please"; } As these security problems have demonstrated, even a simple input from the |