nextcloud/apps/encryption/lib/Exceptions/PrivateKeyMissingException.php

24 lines
559 B
PHP
Raw Normal View History

2015-02-24 13:05:19 -05:00
<?php
/**
* SPDX-FileCopyrightText: 2019-2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
* SPDX-License-Identifier: AGPL-3.0-only
2015-02-24 13:05:19 -05:00
*/
namespace OCA\Encryption\Exceptions;
2015-02-24 13:05:19 -05:00
2015-04-01 10:36:08 -04:00
use OCP\Encryption\Exceptions\GenericEncryptionException;
class PrivateKeyMissingException extends GenericEncryptionException {
2015-02-24 13:05:19 -05:00
2015-04-01 10:36:08 -04:00
/**
* @param string $userId
*/
public function __construct($userId) {
if (empty($userId)) {
2015-04-01 10:36:08 -04:00
$userId = "<no-user-id-given>";
}
parent::__construct("Private Key missing for user: $userId");
}
2015-02-24 13:05:19 -05:00
}