Promises lul
This commit is contained in:
		@@ -36,10 +36,15 @@ export default bot => {
 | 
			
		||||
          fetch(apis.pr0gag.item + id.toString()),
 | 
			
		||||
          id
 | 
			
		||||
        ])
 | 
			
		||||
          .then(([list, item, id]) => [
 | 
			
		||||
            list.json().items.filter(item => item.id === id)[0],
 | 
			
		||||
          .then(([list, item, id]) => Promise.all([
 | 
			
		||||
            list.json(),
 | 
			
		||||
            item.json(),
 | 
			
		||||
            id
 | 
			
		||||
          ]))
 | 
			
		||||
          .then(([list, item, id]) => [
 | 
			
		||||
            list.items.filter(item => item.id === id)[0],
 | 
			
		||||
            item,
 | 
			
		||||
            id
 | 
			
		||||
          ])
 | 
			
		||||
          .then(([list, item, id]) => ({
 | 
			
		||||
            created: list.created,
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user