Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handling of require doesn't work if StandardPackagesPath is changed #32

Closed
fooo opened this issue Jan 6, 2016 · 1 comment
Closed
Assignees
Labels

Comments

@fooo
Copy link

fooo commented Jan 6, 2016

In NeoLuaD / Lua.Libraries.cs there is a return from the loop as soon as LuaRequireCheckFile is called. This means only the first path in paths is checked, so scripts in a path added to StandardPackagesPath will never be found (see line 130 below).

123             foreach (string c in paths) 
124             { 
125                 if (String.IsNullOrEmpty(c)) 
126                     continue; 
127                 else 
128                 { 
129                     sFileName = System.IO.Path.Combine(c, sModName + ".lua"); 
130                     return LuaRequireCheckFile(ref sFileName, ref dtStamp); 
131                 } 
132             } 
@neolithos
Copy link
Owner

Thx.

@neolithos neolithos self-assigned this Jan 6, 2016
@neolithos neolithos added the bug label Jan 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants