Code Duplication    Length = 11-12 lines in 2 locations

lib/Db/CirclesMapper.php 2 locations

@@ 267-278 (lines=12) @@
264
	 *
265
	 * @return string
266
	 */
267
	private function generateTypeEntryForCirclePrivate(IQueryBuilder $qb, int $type) {
268
		if (Circle::CIRCLES_PRIVATE & (int)$type) {
269
			return $qb->expr()
270
					  ->eq(
271
						  'c.type',
272
						  $qb->createNamedParameter(Circle::CIRCLES_PRIVATE)
273
					  );
274
		}
275
276
		return null;
277
	}
278
279
280
	/**
281
	 * @param IQueryBuilder $qb
@@ 286-296 (lines=11) @@
283
	 *
284
	 * @return string
285
	 */
286
	private function generateTypeEntryForCirclePublic(IQueryBuilder $qb, int $type) {
287
		if (Circle::CIRCLES_PUBLIC & (int)$type) {
288
			return $qb->expr()
289
					  ->eq(
290
						  'c.type',
291
						  $qb->createNamedParameter(Circle::CIRCLES_PUBLIC)
292
					  );
293
		}
294
295
		return null;
296
	}
297
298
	/**
299
	 * Returns details about a circle.