File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -528,16 +528,17 @@ public function Console($type='novnc') {
528528 * create {rebuild ...} by changing this parameter
529529 * @return json
530530 */
531- protected function CreateJson (array $ params =array () )
531+ protected function CreateJson ($ params =NULL )
532532 {
533533 // create a blank object
534534 $ obj = new \stdClass ();
535535
536536 // set a bunch of properties
537537 $ obj ->server = new \stdClass ();
538538
539- foreach ($ params as $ key => $ ignore )
540- $ obj ->server ->$ key = $ this ->$ key ;
539+ if (is_array ($ params ))
540+ foreach ($ params as $ key => $ ignore )
541+ $ obj ->server ->$ key = $ this ->$ key ;
541542 $ obj ->server ->imageRef = $ this ->imageRef ;
542543 $ obj ->server ->name = $ this ->name ;
543544 $ obj ->server ->flavorRef = $ this ->flavorRef ;
You can’t perform that action at this time.
0 commit comments