@@ -42,7 +42,7 @@ public static function toObject(array $desc)
4242
4343 // If the constant has an alias, it is declared in the columns section.
4444 // If this is the case, let's wrap it in an "expression"
45- if (isset ($ desc ['alias ' ])) {
45+ if (isset ($ desc ['alias ' ][ ' name ' ] )) {
4646 $ expression = new Expression ();
4747 $ expression ->setBaseExpression ($ desc ['base_expr ' ]);
4848 $ expression ->setSubTree ($ const );
@@ -108,7 +108,7 @@ public static function toObject(array $desc)
108108 $ instance ->setDatabase ($ baseName );
109109 }
110110
111- if (!empty ($ desc ['alias ' ])) {
111+ if (!empty ($ desc ['alias ' ][ ' name ' ] )) {
112112 $ instance ->setAlias ($ desc ['alias ' ]['name ' ]);
113113 }
114114
@@ -225,7 +225,7 @@ public static function toObject(array $desc)
225225 $ expr ->setJoinType ($ desc ['join_type ' ]);
226226 }
227227
228- if (isset ($ desc ['alias ' ])) {
228+ if (isset ($ desc ['alias ' ][ ' name ' ] )) {
229229 $ expr ->setAlias ($ desc ['alias ' ]['name ' ]);
230230 }
231231
@@ -285,7 +285,7 @@ public static function toObject(array $desc)
285285 $ expr ->setSubTree (self ::buildFromSubtree ($ desc ['sub_tree ' ]));
286286 }
287287
288- if (isset ($ desc ['alias ' ])) {
288+ if (isset ($ desc ['alias ' ][ ' name ' ] )) {
289289 $ expr ->setAlias ($ desc ['alias ' ]['name ' ]);
290290 }
291291 if (isset ($ desc ['direction ' ])) {
0 commit comments