Change routing paths to use usernames in web UI (#16171)
This commit is contained in:
		@@ -87,7 +87,7 @@ class Content extends ImmutablePureComponent {
 | 
			
		||||
  onMentionClick = (mention, e) => {
 | 
			
		||||
    if (this.context.router && e.button === 0 && !(e.ctrlKey || e.metaKey)) {
 | 
			
		||||
      e.preventDefault();
 | 
			
		||||
      this.context.router.history.push(`/accounts/${mention.get('id')}`);
 | 
			
		||||
      this.context.router.history.push(`/@${mention.get('acct')}`);
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
@@ -96,14 +96,14 @@ class Content extends ImmutablePureComponent {
 | 
			
		||||
 | 
			
		||||
    if (this.context.router && e.button === 0 && !(e.ctrlKey || e.metaKey)) {
 | 
			
		||||
      e.preventDefault();
 | 
			
		||||
      this.context.router.history.push(`/timelines/tag/${hashtag}`);
 | 
			
		||||
      this.context.router.history.push(`/tags/${hashtag}`);
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  onStatusClick = (status, e) => {
 | 
			
		||||
    if (this.context.router && e.button === 0 && !(e.ctrlKey || e.metaKey)) {
 | 
			
		||||
      e.preventDefault();
 | 
			
		||||
      this.context.router.history.push(`/statuses/${status.get('id')}`);
 | 
			
		||||
      this.context.router.history.push(`/@${status.getIn(['account', 'acct'])}/${status.get('id')}`);
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user