mirror of
https://github.com/weechat/weechat.git
synced 2026-06-25 20:36:38 +02:00
Allow script functions "prefix" and "color" when script is not yet registered with "register"
This commit is contained in:
@@ -3044,12 +3044,6 @@ weechat_lua_api_prefix (lua_State *L)
|
||||
/* make C compiler happy */
|
||||
(void) L;
|
||||
|
||||
if (!lua_current_script || !lua_current_script->name)
|
||||
{
|
||||
WEECHAT_SCRIPT_MSG_NOT_INIT(LUA_CURRENT_SCRIPT_NAME, "prefix");
|
||||
LUA_RETURN_EMPTY;
|
||||
}
|
||||
|
||||
prefix = NULL;
|
||||
|
||||
n = lua_gettop (lua_current_interpreter);
|
||||
@@ -3080,12 +3074,6 @@ weechat_lua_api_color (lua_State *L)
|
||||
/* make C compiler happy */
|
||||
(void) L;
|
||||
|
||||
if (!lua_current_script || !lua_current_script->name)
|
||||
{
|
||||
WEECHAT_SCRIPT_MSG_NOT_INIT(LUA_CURRENT_SCRIPT_NAME, "color");
|
||||
LUA_RETURN_EMPTY;
|
||||
}
|
||||
|
||||
color = NULL;
|
||||
|
||||
n = lua_gettop (lua_current_interpreter);
|
||||
|
||||
Reference in New Issue
Block a user