Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Cool Fire
nanobot4
Commits
51d6114a
Commit
51d6114a
authored
Oct 28, 2018
by
Cool Fire
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make command char use regex escape
parent
e19f0b1f
Pipeline
#993
passed with stages
in 4 minutes and 1 second
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
config.rb
config.rb
+1
-1
ircparser_suroutines.rb
ircparser_suroutines.rb
+1
-1
No files found.
config.rb
View file @
51d6114a
...
...
@@ -9,7 +9,7 @@ class Configuration
@pass
=
""
# NickServ password
@version
=
"Nanobot 4 beta 4"
# Version
@command
=
'
\
?'
# Character prefix for commands
(escape special chars)
@command
=
'?'
# Character prefix for commands
@server
=
"irc.insomnia247.nl"
# IPv4 address
@server6
=
"irc6.insomnia247.nl"
# IPv6 address
...
...
ircparser_suroutines.rb
View file @
51d6114a
...
...
@@ -64,7 +64,7 @@ class IRCSubs
end
def
privmsg
(
nick
,
user
,
host
,
from
,
message
)
cmd
=
@config
.
command
cmd
=
Regexp
.
escape
(
@config
.
command
)
# Fall-through for !# 'do not handle' prefix
if
(
message
=~
/^
#{
cmd
}
#/
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment