commandDispatcher: fix files for Oceanic
This commit is contained in:
		
							parent
							
								
									fba3e3d795
								
							
						
					
					
						commit
						8667189684
					
				
					 1 changed files with 4 additions and 4 deletions
				
			
		| 
						 | 
					@ -86,10 +86,11 @@ async function CommandDispatcher(msg) {
 | 
				
			||||||
      msg.hasRan = true;
 | 
					      msg.hasRan = true;
 | 
				
			||||||
      const response = await runCommand(msg, cmd, line, args);
 | 
					      const response = await runCommand(msg, cmd, line, args);
 | 
				
			||||||
      if (response != null) {
 | 
					      if (response != null) {
 | 
				
			||||||
        let file;
 | 
					 | 
				
			||||||
        if (response.file) {
 | 
					        if (response.file) {
 | 
				
			||||||
          file = response.file;
 | 
					          const files = response.files ?? [];
 | 
				
			||||||
 | 
					          files.push(response.file);
 | 
				
			||||||
          delete response.file;
 | 
					          delete response.file;
 | 
				
			||||||
 | 
					          response.files = files;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        if (response.embed) {
 | 
					        if (response.embed) {
 | 
				
			||||||
          response.embeds = [...(response.embeds ?? []), response.embed];
 | 
					          response.embeds = [...(response.embeds ?? []), response.embed];
 | 
				
			||||||
| 
						 | 
					@ -117,8 +118,7 @@ async function CommandDispatcher(msg) {
 | 
				
			||||||
                    messageID: msg.id,
 | 
					                    messageID: msg.id,
 | 
				
			||||||
                  },
 | 
					                  },
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
              ),
 | 
					              )
 | 
				
			||||||
              file
 | 
					 | 
				
			||||||
            );
 | 
					            );
 | 
				
			||||||
            if (response.addReactions) {
 | 
					            if (response.addReactions) {
 | 
				
			||||||
              for (const index in response.addReactions) {
 | 
					              for (const index in response.addReactions) {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue