Compare commits
	
		
			2 Commits
		
	
	
		
			f1940a7cee
			...
			d80a69920f
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| d80a69920f | |||
| 6ddd607da3 | 
@@ -4,14 +4,17 @@ import { createSource, createSourceOptions, extractImages, downloadImages, getPo
 | 
			
		||||
let nitter = {}
 | 
			
		||||
 | 
			
		||||
export const fetchChannelFromInstances = async (source) => {
 | 
			
		||||
	let index = 0
 | 
			
		||||
	let instances = source.instances
 | 
			
		||||
	let cachedLink = source.cache.link
 | 
			
		||||
    let cachedLinkIndex = source.instances.indexOf(source.cache.link)
 | 
			
		||||
    let index = 0
 | 
			
		||||
    let instances
 | 
			
		||||
	let channel
 | 
			
		||||
    
 | 
			
		||||
	if(cachedLink) {
 | 
			
		||||
		instances.unshift(cachedLink.hostname)
 | 
			
		||||
	}
 | 
			
		||||
    if(cachedLinkIndex !== -1) {
 | 
			
		||||
        instances = source.instances.toSpliced(cachedLinkIndex, 1)
 | 
			
		||||
        instances.unshift(source.instances[cachedLinkIndex])
 | 
			
		||||
    } else {
 | 
			
		||||
        instances = [ ...source.instances ]
 | 
			
		||||
    }
 | 
			
		||||
    
 | 
			
		||||
	while(!channel && index != instances.length) {
 | 
			
		||||
		source.hostname = instances[index]
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user