View Single Post
08-05-14, 09:51 AM   #4
Resike
A Pyroguard Emberseer
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 1,290
Originally Posted by Lombra View Post
It doesn't work exactly like I think that you think it does. What happens here is, when the variables are nil, there will be no entry created in the table, and so, nothing to iterate over. If both of those are nil, it will simply be an empty table.
Yep, the things inside the for loop wont even run, thats why there is no error.
However it's intresting, because you would expect that the pairs call would throw a nil error but it doesn't.
Probably there is a missing nil check in the pairs function, about it's intended or not i'm not sure.

Last edited by Resike : 08-05-14 at 09:57 AM.
  Reply With Quote