if (!canFork) {
// redirect to the summary page if this repository is not empty
GitBlitWebSession.get().cacheErrorMessage(
MessageFormat.format(getString("gb.forkNotAuthorized"), repository.name));
throw new GitblitRedirectException(SummaryPage.class, WicketUtils.newRepositoryParameter(repository.name));
}
String fork = app().repositories().getFork(user.username, repository.name);
if (fork != null) {
// redirect to user's fork
throw new GitblitRedirectException(SummaryPage.class, WicketUtils.newRepositoryParameter(fork));
}
add(new Label("forkText", getString("gb.preparingFork")));
if (!session.isForking()) {