Skip to content
Browse files

fixed a bug in v::string()

  • Loading branch information...
1 parent 56f9685 commit d86fd207917b3862a32f2b7730776f9d29d7e690 @bastianallgeier committed May 31, 2012
Showing with 3 additions and 3 deletions.
  1. +3 −3 kirby.php
View
6 kirby.php
@@ -3,7 +3,7 @@
/**
* Kirby -- A stripped down and easy to use toolkit for PHP
*
- * @version 0.930
+ * @version 0.94
* @author Bastian Allgeier <bastian@getkirby.com>
* @link http://toolkit.getkirby.com
* @copyright Copyright 2009-2012 Bastian Allgeier
@@ -12,7 +12,7 @@
*/
-c::set('version', 0.930);
+c::set('version', 0.94);
c::set('language', 'en');
c::set('charset', 'utf-8');
c::set('root', dirname(__FILE__));
@@ -3268,7 +3268,7 @@ static function string($string, $options) {
$min_length = $max_length = 0;
if(is_array($options)) extract($options);
- if($format && !preg_match('/^[$format]*$/is', $string)) return false;
+ if($format && !preg_match('/^[' . $format . ']*$/is', $string)) return false;
if($min_length && str::length($string) < $min_length) return false;
if($max_length && str::length($string) > $max_length) return false;
return true;

0 comments on commit d86fd20

Please sign in to comment.
Something went wrong with that request. Please try again.