Skip to content

Commit c912df3

Browse files
committed
Fix value returned in error path of client.show_future
fixes 6223c9d
1 parent 9531325 commit c912df3

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/BizHawk.Client.Common/lua/CommonLibs/ClientLuaLibrary.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ public string ShowFuture(LuaFunction luaf, long maxFrames, string name = null)
291291
if (maxFrames < 1 || maxFrames > short.MaxValue)
292292
{
293293
Log($"Invalid number of future frames ({maxFrames}); number must be positive and less than 2^15.");
294-
return "";
294+
return EventsLuaLibrary.EMPTY_UUID_STR;
295295
}
296296

297297
INamedLuaFunction nlf = CreateAndRegisterNamedFunction(luaf, NamedLuaFunction.EVENT_TYPE_FUTURE, prohibitedApis: ApiGroup.PROHIBITED_MID_FRAME, name: name);

src/BizHawk.Client.Common/lua/LuaHelperLibs/EventsLuaLibrary.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ namespace BizHawk.Client.Common
1010
[Description("A library for registering lua functions to emulator events.\n All events support multiple registered methods.\nAll registered event methods can be named and return a Guid when registered")]
1111
public sealed class EventsLuaLibrary : LuaLibraryBase, IRegisterFunctions
1212
{
13-
private static readonly string EMPTY_UUID_STR = Guid.Empty.ToString("D");
13+
internal static readonly string EMPTY_UUID_STR = Guid.Empty.ToString("D");
1414

1515
public NLFAddCallback CreateAndRegisterNamedFunction { get; set; }
1616

0 commit comments

Comments
 (0)