fix PHP Fatal error: Cannot redeclare class Generator on PHP 5.5

PHP 5.5 STL introdouced class Generator and PHP interpret thinks we want to redeclare it -> rename Generator class to something else
This commit is contained in:
Tomas Kasparek
2015-07-08 13:33:37 +02:00
parent faef7e7602
commit ec18bd788c
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -9,7 +9,7 @@
## ##
#################################################################################
class Generator {
class MyGenerator {
public function generateRandID(){
return md5($this->generateRandStr(16));
@@ -162,4 +162,4 @@ if (date('Ymd',time()) == date('Ymd',$time)) {
}
};
$generator = new Generator;
$generator = new MyGenerator;