Skip to content

Commit

Permalink
fix buffer debugname is optional
Browse files Browse the repository at this point in the history
  • Loading branch information
nikeinikei committed Dec 13, 2023
1 parent a5d7ba1 commit 8343983
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/modules/graphics/wrap_Graphics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1576,10 +1576,11 @@ static void luax_optbuffersettings(lua_State *L, int idx, Buffer::Settings &sett

lua_getfield(L, idx, "usage");
settings.dataUsage = luax_optdatausage(L, -1, settings.dataUsage);
lua_pop(L, 1);

lua_getfield(L, idx, "debugname");
settings.debugName = luax_checkstring(L, -1);

if (!lua_isnoneornil(L, -1))
settings.debugName = luax_checkstring(L, -1);
lua_pop(L, 1);
}

Expand Down

0 comments on commit 8343983

Please sign in to comment.