mirror of
https://github.com/weechat/weechat.git
synced 2026-06-26 04:46:37 +02:00
Allow script functions "prefix" and "color" when script is not yet registered with "register"
This commit is contained in:
@@ -2556,12 +2556,6 @@ XS (XS_weechat_api_prefix)
|
||||
/* make C compiler happy */
|
||||
(void) cv;
|
||||
|
||||
if (!perl_current_script || !perl_current_script->name)
|
||||
{
|
||||
WEECHAT_SCRIPT_MSG_NOT_INIT(PERL_CURRENT_SCRIPT_NAME, "prefix");
|
||||
PERL_RETURN_EMPTY;
|
||||
}
|
||||
|
||||
if (items < 1)
|
||||
{
|
||||
WEECHAT_SCRIPT_MSG_WRONG_ARGS(PERL_CURRENT_SCRIPT_NAME, "prefix");
|
||||
@@ -2585,12 +2579,6 @@ XS (XS_weechat_api_color)
|
||||
/* make C compiler happy */
|
||||
(void) cv;
|
||||
|
||||
if (!perl_current_script || !perl_current_script->name)
|
||||
{
|
||||
WEECHAT_SCRIPT_MSG_NOT_INIT(PERL_CURRENT_SCRIPT_NAME, "color");
|
||||
PERL_RETURN_EMPTY;
|
||||
}
|
||||
|
||||
if (items < 1)
|
||||
{
|
||||
WEECHAT_SCRIPT_MSG_WRONG_ARGS(PERL_CURRENT_SCRIPT_NAME, "color");
|
||||
|
||||
Reference in New Issue
Block a user