mirror of
				https://github.com/superseriousbusiness/gotosocial.git
				synced 2025-10-30 22:02:25 -05:00 
			
		
		
		
	rewrite calls to public / local timeline calls
This commit is contained in:
		
					parent
					
						
							
								374f0f5175
							
						
					
				
			
			
				commit
				
					
						daa83cfd0d
					
				
			
		
					 1 changed files with 8 additions and 8 deletions
				
			
		|  | @ -83,16 +83,16 @@ func (p *Processor) publicTimelineGet( | ||||||
| 
 | 
 | ||||||
| 		// Pre-filtering function, | 		// Pre-filtering function, | ||||||
| 		// i.e. filter before caching. | 		// i.e. filter before caching. | ||||||
| 		nil, |  | ||||||
| 
 |  | ||||||
| 		// Post-filtering function, |  | ||||||
| 		// i.e. filter after caching. |  | ||||||
| 		func(s *gtsmodel.Status) (bool, error) { | 		func(s *gtsmodel.Status) (bool, error) { | ||||||
| 
 | 
 | ||||||
| 			// Check the visibility of passed status to requesting user. | 			// Check the visibility of passed status to requesting user. | ||||||
| 			ok, err := p.visFilter.StatusPublicTimelineable(ctx, requester, s) | 			ok, err := p.visFilter.StatusPublicTimelineable(ctx, requester, s) | ||||||
| 			return !ok, err | 			return !ok, err | ||||||
| 		}, | 		}, | ||||||
|  | 
 | ||||||
|  | 		// Post-filtering function, | ||||||
|  | 		// i.e. filter after caching. | ||||||
|  | 		nil, | ||||||
| 	) | 	) | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | @ -136,15 +136,15 @@ func (p *Processor) localTimelineGet( | ||||||
| 
 | 
 | ||||||
| 		// Pre-filtering function, | 		// Pre-filtering function, | ||||||
| 		// i.e. filter before caching. | 		// i.e. filter before caching. | ||||||
| 		nil, |  | ||||||
| 
 |  | ||||||
| 		// Post-filtering function, |  | ||||||
| 		// i.e. filter after caching. |  | ||||||
| 		func(s *gtsmodel.Status) (bool, error) { | 		func(s *gtsmodel.Status) (bool, error) { | ||||||
| 
 | 
 | ||||||
| 			// Check the visibility of passed status to requesting user. | 			// Check the visibility of passed status to requesting user. | ||||||
| 			ok, err := p.visFilter.StatusPublicTimelineable(ctx, requester, s) | 			ok, err := p.visFilter.StatusPublicTimelineable(ctx, requester, s) | ||||||
| 			return !ok, err | 			return !ok, err | ||||||
| 		}, | 		}, | ||||||
|  | 
 | ||||||
|  | 		// Post-filtering function, | ||||||
|  | 		// i.e. filter after caching. | ||||||
|  | 		nil, | ||||||
| 	) | 	) | ||||||
| } | } | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue