mirror of
https://github.com/love2d/love.git
synced 2026-08-17 19:23:38 +02:00
Allow require paths without replacements
--HG-- branch : minor
This commit is contained in:
@@ -558,10 +558,9 @@ int loader(lua_State *L)
|
|||||||
for (std::string element : inst->getRequirePath())
|
for (std::string element : inst->getRequirePath())
|
||||||
{
|
{
|
||||||
size_t pos = element.find('?');
|
size_t pos = element.find('?');
|
||||||
if (pos == std::string::npos)
|
if (pos != std::string::npos)
|
||||||
continue;
|
element.replace(pos, 1, modulename);
|
||||||
|
|
||||||
element.replace(pos, 1, modulename);
|
|
||||||
if (inst->isFile(element.c_str()))
|
if (inst->isFile(element.c_str()))
|
||||||
{
|
{
|
||||||
lua_pop(L, 1);
|
lua_pop(L, 1);
|
||||||
|
|||||||
Reference in New Issue
Block a user