Code Duplication    Length = 11-11 lines in 2 locations

apps/dav/lib/CalDAV/Activity/Provider/Base.php 1 location

@@ 157-167 (lines=11) @@
154
	 * @param string $gid
155
	 * @return array
156
	 */
157
	protected function generateGroupParameter($gid) {
158
		if (!isset($this->groupDisplayNames[$gid])) {
159
			$this->groupDisplayNames[$gid] = $this->getGroupDisplayName($gid);
160
		}
161
162
		return [
163
			'type' => 'group',
164
			'id' => $gid,
165
			'name' => $this->groupDisplayNames[$gid],
166
		];
167
	}
168
169
	/**
170
	 * @param string $gid

apps/files_sharing/lib/Activity/Providers/Groups.php 1 location

@@ 147-157 (lines=11) @@
144
	 * @param string $gid
145
	 * @return array
146
	 */
147
	protected function generateGroupParameter($gid) {
148
		if (!isset($this->groupDisplayNames[$gid])) {
149
			$this->groupDisplayNames[$gid] = $this->getGroupDisplayName($gid);
150
		}
151
152
		return [
153
			'type' => 'group',
154
			'id' => $gid,
155
			'name' => $this->groupDisplayNames[$gid],
156
		];
157
	}
158
159
	/**
160
	 * @param string $gid