Proxy image requests.
This commit is contained in:
		
							parent
							
								
									70da8248cc
								
							
						
					
					
						commit
						2ba7cd9ebd
					
				@ -182,6 +182,9 @@ class Server {
 | 
			
		||||
      this.app
 | 
			
		||||
        .get(config.API_ENDPOINT + 'donations', (req, res) => {
 | 
			
		||||
          req.pipe(request('https://mempool.space/api/v1/donations')).pipe(res);
 | 
			
		||||
        })
 | 
			
		||||
        .get(config.API_ENDPOINT + 'donations/images/:id', (req, res) => {
 | 
			
		||||
          req.pipe(request('https://mempool.space/api/v1/donations/images/' + req.params.id)).pipe(res);
 | 
			
		||||
        });
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user