James Moger
2013-05-10 22ad1f4ce45615c888944b40f27916291f7ffad7
src/main/java/com/gitblit/wicket/pages/BasePage.java
@@ -35,7 +35,6 @@
import org.apache.wicket.MarkupContainer;
import org.apache.wicket.PageParameters;
import org.apache.wicket.RedirectToUrlException;
import org.apache.wicket.RequestCycle;
import org.apache.wicket.RestartResponseException;
import org.apache.wicket.markup.html.CSSPackageResource;
import org.apache.wicket.markup.html.basic.Label;
@@ -56,7 +55,6 @@
import com.gitblit.GitBlit;
import com.gitblit.Keys;
import com.gitblit.models.ProjectModel;
import com.gitblit.models.RepositoryModel;
import com.gitblit.models.TeamModel;
import com.gitblit.models.UserModel;
import com.gitblit.utils.StringUtils;
@@ -253,21 +251,6 @@
      ServletWebRequest servletWebRequest = (ServletWebRequest) getRequest();
      HttpServletRequest req = servletWebRequest.getHttpServletRequest();
      return req.getServerName();
   }
   public static String getRepositoryUrl(RepositoryModel repository) {
      StringBuilder sb = new StringBuilder();
      sb.append(WicketUtils.getGitblitURL(RequestCycle.get().getRequest()));
      sb.append(Constants.GIT_PATH);
      sb.append(repository.name);
      // inject username into repository url if authentication is required
      if (repository.accessRestriction.exceeds(AccessRestrictionType.NONE)
            && GitBlitWebSession.get().isLoggedIn()) {
         String username = GitBlitWebSession.get().getUsername();
         sb.insert(sb.indexOf("://") + 3, username + "@");
      }
      return sb.toString();
   }
   
   protected List<ProjectModel> getProjectModels() {