1
0

GenericShareException.php 801 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. /**
  3. * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
  4. * SPDX-FileCopyrightText: 2016 ownCloud, Inc.
  5. * SPDX-License-Identifier: AGPL-3.0-only
  6. */
  7. namespace OCP\Share\Exceptions;
  8. use OCP\HintException;
  9. /**
  10. * Class GenericEncryptionException
  11. *
  12. * @since 9.0.0
  13. */
  14. class GenericShareException extends HintException {
  15. /**
  16. * @param string $message
  17. * @param string $hint
  18. * @param int $code
  19. * @param \Exception|null $previous
  20. * @since 9.0.0
  21. */
  22. public function __construct($message = '', $hint = '', $code = 0, ?\Exception $previous = null) {
  23. if (empty($message)) {
  24. $message = 'There was an error retrieving the share. Maybe the link is wrong, it was unshared, or it was deleted.';
  25. }
  26. parent::__construct($message, $hint, $code, $previous);
  27. }
  28. }