Code Duplication    Length = 7-7 lines in 2 locations

engine/classes/ElggUser.php 1 location

@@ 58-64 (lines=7) @@
55
		switch ($name) {
56
			case 'prev_last_action':
57
			case 'last_login':
58
			case 'prev_last_login':
59
				if ($value !== null) {
60
					$this->attributes[$name] = (int) $value;
61
				} else {
62
					$this->attributes[$name] = null;
63
				}
64
				break;
65
66
			case 'salt':
67
			case 'password':

engine/classes/ElggEntity.php 1 location

@@ 225-231 (lines=7) @@
222
					break;
223
				case 'access_id':
224
				case 'owner_guid':
225
				case 'container_guid':
226
					if ($value !== null) {
227
						$this->attributes[$name] = (int) $value;
228
					} else {
229
						$this->attributes[$name] = null;
230
					}
231
					break;
232
				default:
233
					$this->attributes[$name] = $value;
234
					break;