Code Duplication    Length = 7-7 lines in 3 locations

lib/Navigation.php 1 location

@@ 113-119 (lines=7) @@
110
	 */
111
	public function getLinkList() {
112
		$filters = $this->activityManager->getFilters();
113
		usort($filters, function(IFilter $a, IFilter $b) {
114
			if ($a->getPriority() === $b->getPriority()) {
115
				return $a->getIdentifier() > $b->getIdentifier();
116
			}
117
118
			return $a->getPriority() > $b->getPriority();
119
		});
120
121
		$entries = [];
122
		foreach ($filters as $filter) {

lib/Settings/Admin.php 1 location

@@ 65-71 (lines=7) @@
62
	 */
63
	public function getForm() {
64
		$settings = $this->manager->getSettings();
65
		usort($settings, function(ISetting $a, ISetting $b) {
66
			if ($a->getPriority() === $b->getPriority()) {
67
				return $a->getIdentifier() > $b->getIdentifier();
68
			}
69
70
			return $a->getPriority() > $b->getPriority();
71
		});
72
73
		$activities = [];
74
		foreach ($settings as $setting) {

lib/Controller/Settings.php 1 location

@@ 228-234 (lines=7) @@
225
	 */
226
	public function displayPanel() {
227
		$settings = $this->manager->getSettings();
228
		usort($settings, function(ISetting $a, ISetting $b) {
229
			if ($a->getPriority() === $b->getPriority()) {
230
				return $a->getIdentifier() > $b->getIdentifier();
231
			}
232
233
			return $a->getPriority() > $b->getPriority();
234
		});
235
236
		$activities = [];
237
		foreach ($settings as $setting) {