one last round of nil checks
This commit is contained in:
		
							parent
							
								
									0de38f49a8
								
							
						
					
					
						commit
						a7f0295fed
					
				
					 2 changed files with 9 additions and 3 deletions
				
			
		|  | @ -135,8 +135,10 @@ end | ||||||
| if shouldInstall then | if shouldInstall then | ||||||
|     local files = getAllFiles(programToInstall) |     local files = getAllFiles(programToInstall) | ||||||
|     for _, value in ipairs(files) do |     for _, value in ipairs(files) do | ||||||
|  |         if value ~= nil then | ||||||
|             downloadFile(programToInstall, value) |             downloadFile(programToInstall, value) | ||||||
|         end |         end | ||||||
|  |     end | ||||||
|     finishInstall(programToInstall, files) |     finishInstall(programToInstall, files) | ||||||
| elseif fs.exists(path .. "updater/update.lua") then | elseif fs.exists(path .. "updater/update.lua") then | ||||||
|     shell.run(path .. "updater/update.lua " .. programToInstall) |     shell.run(path .. "updater/update.lua " .. programToInstall) | ||||||
|  |  | ||||||
|  | @ -147,8 +147,10 @@ if programToInstall == nil then | ||||||
|             local files = getAllFiles(value) |             local files = getAllFiles(value) | ||||||
|             if files ~= nil then |             if files ~= nil then | ||||||
|                 for _, value2 in ipairs(files) do |                 for _, value2 in ipairs(files) do | ||||||
|  |                     if value2 ~= nil then | ||||||
|                         downloadFile(value, value2) |                         downloadFile(value, value2) | ||||||
|                     end |                     end | ||||||
|  |                 end | ||||||
|                 finishInstall(files) |                 finishInstall(files) | ||||||
|             end |             end | ||||||
|         end |         end | ||||||
|  | @ -161,8 +163,10 @@ else | ||||||
|         print("no updates found.") |         print("no updates found.") | ||||||
|     else |     else | ||||||
|         for _, value in ipairs(files) do |         for _, value in ipairs(files) do | ||||||
|  |             if value ~= nil then | ||||||
|                 downloadFile(programToInstall, value) |                 downloadFile(programToInstall, value) | ||||||
|             end |             end | ||||||
|  |         end | ||||||
|         finishInstall(programToInstall, files) |         finishInstall(programToInstall, files) | ||||||
|     end |     end | ||||||
| end | end | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue