Code Duplication    Length = 4-4 lines in 2 locations

lib/private/Share20/Manager.php 2 locations

@@ 254-257 (lines=4) @@
251
		}
252
253
		if ($share->getNode() instanceof \OCP\Files\File) {
254
			if ($share->getPermissions() & \OCP\Constants::PERMISSION_DELETE) {
255
				$message_t = $this->l->t('Files can\'t be shared with delete permissions');
256
				throw new GenericShareException($message_t);
257
			}
258
			if ($share->getPermissions() & \OCP\Constants::PERMISSION_CREATE) {
259
				$message_t = $this->l->t('Files can\'t be shared with create permissions');
260
				throw new GenericShareException($message_t);
@@ 258-261 (lines=4) @@
255
				$message_t = $this->l->t('Files can\'t be shared with delete permissions');
256
				throw new GenericShareException($message_t);
257
			}
258
			if ($share->getPermissions() & \OCP\Constants::PERMISSION_CREATE) {
259
				$message_t = $this->l->t('Files can\'t be shared with create permissions');
260
				throw new GenericShareException($message_t);
261
			}
262
		}
263
	}
264