Code Duplication    Length = 3-3 lines in 2 locations

apps/dav/lib/Comments/CommentsPlugin.php 1 location

@@ 177-179 (lines=3) @@
174
			$args[str_replace($ns, '', $parameter['name'])] = $parameter['value'];
175
		}
176
177
		if(!is_null($args['datetime'])) {
178
			$args['datetime'] = new \DateTime($args['datetime']);
179
		}
180
181
		$results = $node->findChildren($args['limit'], $args['offset'], $args['datetime']);
182

lib/private/Comments/Manager.php 1 location

@@ 90-92 (lines=3) @@
87
		$data['parent_id'] = strval($data['parent_id']);
88
		$data['topmost_parent_id'] = strval($data['topmost_parent_id']);
89
		$data['creation_timestamp'] = new \DateTime($data['creation_timestamp']);
90
		if (!is_null($data['latest_child_timestamp'])) {
91
			$data['latest_child_timestamp'] = new \DateTime($data['latest_child_timestamp']);
92
		}
93
		$data['children_count'] = intval($data['children_count']);
94
		return $data;
95
	}