Code Duplication    Length = 5-8 lines in 2 locations

src/Commands/ModelCommand.php 2 locations

@@ 97-101 (lines=5) @@
94
            foreach ($items as $item) {
95
                $item['type'] = $type;
96
				if ($parser == 'relations') {
97
					if(! $item['model']){
98
	                    $item['model'] = $this->getNamespace() . '\\' . ucwords(str_singular($item['name']));
99
	                } else if(strpos($item['model'], '\\') === false ){
100
	                    $item['model'] = $this->getNamespace() . '\\' . $item['model'];
101
	                }
102
				} else if ($parser != 'relations') {
103
					switch($type) {
104
						case "hasManyThrough":
@@ 115-122 (lines=8) @@
112
								if(strpos($item['model'], '\\') === false ){
113
									$item['model'] = $this->getNamespace() . '\\' . ucwords(str_singular($item['model']));
114
								}
115
							} else {
116
								if(strpos($item['through'], '\\') === false ){
117
									$item['through'] = $this->getNamespace() . '\\' . $item['through'];
118
								}
119
								if(strpos($item['model'], '\\') === false ){
120
									$item['model'] = $this->getNamespace() . '\\' . $item['model'];
121
								}
122
							}
123
							break;
124
						case "morphMany":
125
						case "morphToMany":