@@ -174,7 +174,7 @@ |
||
174 | 174 | break; |
175 | 175 | } |
176 | 176 | if ( $default !== null |
177 | - // we need to skip working links because in this case, Doctrine expects objects as values |
|
177 | + // we need to skip working links because in this case, Doctrine expects objects as values |
|
178 | 178 | && ( !$property->link |
179 | 179 | || $this->manager->resolve_targetclass($property) === false)) { |
180 | 180 | $line .= ' = ' . $default; |
@@ -62,8 +62,8 @@ discard block |
||
62 | 62 | } |
63 | 63 | |
64 | 64 | $types = $this->manager->get_types(); |
65 | - uasort($types, function ($a, $b) { |
|
66 | - if ( !empty($a->extends) |
|
65 | + uasort($types, function($a, $b) { |
|
66 | + if (!empty($a->extends) |
|
67 | 67 | && !empty($b->extends)) { |
68 | 68 | return strnatcmp($a->extends, $b->extends); |
69 | 69 | } elseif (!empty($a->extends)) { |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | $prefix = $this->get_class_prefix($namespace); |
105 | 105 | |
106 | 106 | foreach ($this->manager->get_types() as $type) { |
107 | - if ( $prefix !== '' |
|
107 | + if ($prefix !== '' |
|
108 | 108 | && !class_exists($type->name)) { |
109 | 109 | $this->add_line('class_alias( "' . $prefix . $type->name . '", "' . $type->name . '");'); |
110 | 110 | } |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | |
113 | 113 | foreach ($this->manager->get_inherited_mapping() as $child => $parent) { |
114 | 114 | $this->add_line('class_alias( "' . $prefix . $parent . '", "' . $prefix . $child . '");'); |
115 | - if ( $prefix !== '' |
|
115 | + if ($prefix !== '' |
|
116 | 116 | && !class_exists($child)) { |
117 | 117 | $this->add_line('class_alias( "' . $prefix . $parent . '", "' . $child . '");'); |
118 | 118 | } |
@@ -173,9 +173,9 @@ discard block |
||
173 | 173 | $objects[$name] = 'new midgard_datetime("0001-01-01 00:00:00")'; |
174 | 174 | break; |
175 | 175 | } |
176 | - if ( $default !== null |
|
176 | + if ($default !== null |
|
177 | 177 | // we need to skip working links because in this case, Doctrine expects objects as values |
178 | - && ( !$property->link |
|
178 | + && (!$property->link |
|
179 | 179 | || $this->manager->resolve_targetclass($property) === false)) { |
180 | 180 | $line .= ' = ' . $default; |
181 | 181 | } |
@@ -235,7 +235,7 @@ discard block |
||
235 | 235 | $this->write_annotations($type); |
236 | 236 | $this->add_line('class ' . $type->name . ' extends ' . $type->extends); |
237 | 237 | $mixins = $type->get_mixins(); |
238 | - $interfaces = array_filter(array_map(function ($name) { |
|
238 | + $interfaces = array_filter(array_map(function($name) { |
|
239 | 239 | if (interface_exists('\\midgard\\portable\\storage\\interfaces\\' . $name)) { |
240 | 240 | return '\\midgard\\portable\\storage\\interfaces\\' . $name; |
241 | 241 | } |
@@ -65,7 +65,7 @@ |
||
65 | 65 | } else { |
66 | 66 | if ($property->parentfield) { |
67 | 67 | $this->parentfield = $property->name; |
68 | - if ( empty($this->parent) |
|
68 | + if (empty($this->parent) |
|
69 | 69 | && $property->link) { |
70 | 70 | $this->parent = $property->link['target']; |
71 | 71 | } |
@@ -78,7 +78,7 @@ |
||
78 | 78 | $fqcn = $this->namespace . '\\' . $fqcn; |
79 | 79 | } |
80 | 80 | |
81 | - if ( array_key_exists($fqcn, $this->types) |
|
81 | + if (array_key_exists($fqcn, $this->types) |
|
82 | 82 | || $property->link['target'] === $property->get_parent()->name) { |
83 | 83 | $target_class = $property->link['target']; |
84 | 84 | } else { |