Show More
@@ -461,20 +461,20 b' class RepoRoutePredicate(object):' | |||
|
461 | 461 | phash = text |
|
462 | 462 | |
|
463 | 463 | def __call__(self, info, request): |
|
464 | ||
|
465 | 464 | if hasattr(request, 'vcs_call'): |
|
466 | 465 | # skip vcs calls |
|
467 | 466 | return |
|
468 | 467 | |
|
469 | 468 | repo_name = info['match']['repo_name'] |
|
470 | 469 | repo_model = repo.RepoModel() |
|
471 | by_name_match = repo_model.get_by_repo_name(repo_name, cache=True) | |
|
470 | ||
|
471 | by_name_match = repo_model.get_by_repo_name(repo_name, cache=False) | |
|
472 | 472 | |
|
473 | 473 | def redirect_if_creating(db_repo): |
|
474 | 474 | if db_repo.repo_state in [repo.Repository.STATE_PENDING]: |
|
475 | raise HTTPFound( | |
|
476 |
|
|
|
477 | repo_name=db_repo.repo_name)) | |
|
475 | repo_creating_url = request.route_path( | |
|
476 | 'repo_creating', repo_name=db_repo.repo_name) | |
|
477 | raise HTTPFound(repo_creating_url) | |
|
478 | 478 | |
|
479 | 479 | if by_name_match: |
|
480 | 480 | # register this as request object we can re-use later |
@@ -516,7 +516,7 b' class RepoTypeRoutePredicate(object):' | |||
|
516 | 516 | else: |
|
517 | 517 | log.warning('Current view is not supported for repo type:%s', |
|
518 | 518 | rhodecode_db_repo.repo_type) |
|
519 | # | |
|
519 | ||
|
520 | 520 | # h.flash(h.literal( |
|
521 | 521 | # _('Action not supported for %s.' % rhodecode_repo.alias)), |
|
522 | 522 | # category='warning') |
@@ -542,8 +542,7 b' class RepoGroupRoutePredicate(object):' | |||
|
542 | 542 | |
|
543 | 543 | repo_group_name = info['match']['repo_group_name'] |
|
544 | 544 | repo_group_model = repo_group.RepoGroupModel() |
|
545 | by_name_match = repo_group_model.get_by_group_name( | |
|
546 | repo_group_name, cache=True) | |
|
545 | by_name_match = repo_group_model.get_by_group_name(repo_group_name, cache=False) | |
|
547 | 546 | |
|
548 | 547 | if by_name_match: |
|
549 | 548 | # register this as request object we can re-use later |
@@ -569,8 +568,7 b' class UserGroupRoutePredicate(object):' | |||
|
569 | 568 | |
|
570 | 569 | user_group_id = info['match']['user_group_id'] |
|
571 | 570 | user_group_model = user_group.UserGroup() |
|
572 | by_id_match = user_group_model.get( | |
|
573 | user_group_id, cache=True) | |
|
571 | by_id_match = user_group_model.get(user_group_id, cache=False) | |
|
574 | 572 | |
|
575 | 573 | if by_id_match: |
|
576 | 574 | # register this as request object we can re-use later |
@@ -596,8 +594,7 b' class UserRoutePredicateBase(object):' | |||
|
596 | 594 | |
|
597 | 595 | user_id = info['match']['user_id'] |
|
598 | 596 | user_model = user.User() |
|
599 | by_id_match = user_model.get( | |
|
600 | user_id, cache=True) | |
|
597 | by_id_match = user_model.get(user_id, cache=False) | |
|
601 | 598 | |
|
602 | 599 | if by_id_match: |
|
603 | 600 | # register this as request object we can re-use later |
General Comments 0
You need to be logged in to leave comments.
Login now