mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-13 00:45:44 +01:00
Remove special RepositoryNotFoundException
This commit is contained in:
@@ -198,7 +198,7 @@ public class DefaultRepositoryManager extends AbstractRepositoryManager {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void refresh(Repository repository) throws RepositoryNotFoundException {
|
||||
public void refresh(Repository repository) {
|
||||
AssertUtil.assertIsNotNull(repository);
|
||||
RepositoryPermissions.read(repository).check();
|
||||
|
||||
@@ -207,7 +207,7 @@ public class DefaultRepositoryManager extends AbstractRepositoryManager {
|
||||
if (fresh != null) {
|
||||
fresh.copyProperties(repository);
|
||||
} else {
|
||||
throw new RepositoryNotFoundException(repository);
|
||||
throw NotFoundException.notFound(repository).build();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ public final class HealthChecker {
|
||||
Repository repository = repositoryManager.get(id);
|
||||
|
||||
if (repository == null) {
|
||||
throw new RepositoryNotFoundException(id);
|
||||
throw new NotFoundException(Repository.class, id);
|
||||
}
|
||||
|
||||
doCheck(repository);
|
||||
|
||||
Reference in New Issue
Block a user