mirror of
https://github.com/projectdiscovery/nuclei.git
synced 2025-12-22 11:55:27 +00:00
remove deprecated dsl helper func
This commit is contained in:
parent
ef8ef8edb3
commit
237cb0bc79
@ -19,10 +19,10 @@ var (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
_ = dsl.AddMultiSignatureHelperFunction("resolve", []string{
|
_ = dsl.AddFunction(dsl.NewWithMultipleSignatures("resolve", []string{
|
||||||
"(host string) string",
|
"(host string) string",
|
||||||
"(format string) string",
|
"(format string) string",
|
||||||
}, func(args ...interface{}) (interface{}, error) {
|
}, false, func(args ...interface{}) (interface{}, error) {
|
||||||
argCount := len(args)
|
argCount := len(args)
|
||||||
if argCount == 0 || argCount > 2 {
|
if argCount == 0 || argCount > 2 {
|
||||||
return nil, dsl.ErrInvalidDslFunction
|
return nil, dsl.ErrInvalidDslFunction
|
||||||
@ -94,7 +94,7 @@ func init() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return "", fmt.Errorf("no records found")
|
return "", fmt.Errorf("no records found")
|
||||||
})
|
}))
|
||||||
|
|
||||||
dsl.PrintDebugCallback = func(args ...interface{}) error {
|
dsl.PrintDebugCallback = func(args ...interface{}) error {
|
||||||
gologger.Info().Msgf("print_debug value: %s", fmt.Sprint(args))
|
gologger.Info().Msgf("print_debug value: %s", fmt.Sprint(args))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user