Code Duplication    Length = 11-12 lines in 2 locations

lib/Db/CirclesMapper.php 2 locations

@@ 251-262 (lines=12) @@
248
	 *
249
	 * @return string
250
	 */
251
	private function generateTypeEntryForCirclePrivate(IQueryBuilder $qb, int $type) {
252
		if (Circle::CIRCLES_PRIVATE & (int)$type) {
253
			return $qb->expr()
254
					  ->eq(
255
						  'c.type',
256
						  $qb->createNamedParameter(Circle::CIRCLES_PRIVATE)
257
					  );
258
		}
259
260
		return null;
261
	}
262
263
264
	/**
265
	 * @param IQueryBuilder $qb
@@ 270-280 (lines=11) @@
267
	 *
268
	 * @return string
269
	 */
270
	private function generateTypeEntryForCirclePublic(IQueryBuilder $qb, int $type) {
271
		if (Circle::CIRCLES_PUBLIC & (int)$type) {
272
			return $qb->expr()
273
					  ->eq(
274
						  'c.type',
275
						  $qb->createNamedParameter(Circle::CIRCLES_PUBLIC)
276
					  );
277
		}
278
279
		return null;
280
	}
281
282
	/**
283
	 * Returns details about a circle.