Undefined argument in util.loadfilemods

Moderator: Moderator

Post Reply
Message
Author
yufra
Perspiring Physicist
Posts: 1332
Joined: Tue Jul 13, 2010 2:53 pm

Undefined argument in util.loadfilemods

#1 Post by yufra »

I am poking around at the addon code and believe that I have a found an undefined `bname` variable inside of `util.loadfilemods`:

Code: Select all

1002 function util.loadfilemods(file, env)
...
1017                                         local ok, err = pcall(base, bname)
The `base` variable is the function returned by `loadfile`, so I don't think that it accepts any arguments anyway. If I am not understanding can you explain what is going on? Cheers!

EDIT: I got there eventually. :D DG is doing some fancy magic with the `te4_loader` function and `package.loaders`, so nothing to see here. Unless you want to understand how the addons are actually implemented that is.
<DarkGod> lets say it's intended

Post Reply