Code Duplication    Length = 11-12 lines in 2 locations

lib/Db/CirclesMapper.php 2 locations

@@ 225-236 (lines=12) @@
222
	 *
223
	 * @return string
224
	 */
225
	private function generateTypeEntryForCirclePrivate(IQueryBuilder $qb, int $type) {
226
		if (Circle::CIRCLES_PRIVATE & (int)$type) {
227
			return $qb->expr()
228
					  ->eq(
229
						  'c.type',
230
						  $qb->createNamedParameter(Circle::CIRCLES_PRIVATE)
231
					  );
232
		}
233
234
		return null;
235
	}
236
237
238
	/**
239
	 * @param IQueryBuilder $qb
@@ 244-254 (lines=11) @@
241
	 *
242
	 * @return string
243
	 */
244
	private function generateTypeEntryForCirclePublic(IQueryBuilder $qb, int $type) {
245
		if (Circle::CIRCLES_PUBLIC & (int)$type) {
246
			return $qb->expr()
247
					  ->eq(
248
						  'c.type',
249
						  $qb->createNamedParameter(Circle::CIRCLES_PUBLIC)
250
					  );
251
		}
252
253
		return null;
254
	}
255
256
	/**
257
	 * Returns details about a circle.