changeset 547:717a1c84df4c

quotedb: Rename qdb_command() to qdb_cmd()
author Matti Hamalainen <ccr@tnsp.org>
date Wed, 08 Jul 2020 12:12:57 +0300
parents 21aee5c2835c
children 028ee7efd4ff
files config.quotedb.example quotedb.tcl
diffstat 2 files changed, 11 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/config.quotedb.example	Wed Jul 08 01:47:38 2020 +0300
+++ b/config.quotedb.example	Wed Jul 08 12:12:57 2020 +0300
@@ -11,8 +11,8 @@
 # Bind !quote -command for table "quotedb"
 bind pub - !vitsi vitsi_cmd_pub
 bind msg - !vitsi vitsi_cmd_msg
-proc vitsi_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!vitsi" "quotedb" $unick $uhost $uhand $uchan $utext 1 }
-proc vitsi_cmd_msg {unick uhost uhand utext}       { qdb_command "!vitsi" "quotedb" $unick $uhost $uhand "" $utext 0 }
+proc vitsi_cmd_pub {unick uhost uhand uchan utext} { qdb_cmd "!vitsi" "quotedb" $unick $uhost $uhand $uchan $utext 1 }
+proc vitsi_cmd_msg {unick uhost uhand utext}       { qdb_cmd "!vitsi" "quotedb" $unick $uhost $uhand "" $utext 0 }
 set qdb_messages(quotedb_fmt_get) "@2@ (#@1@)"
 set qdb_messages(quotedb_urlprefix) ""
 set qdb_messages(quotedb_name) "Vitsi"
@@ -21,8 +21,8 @@
 # Bind !quote -command for table "kissa"
 bind pub - !kissa kissa_cmd_pub
 bind msg - !kissa kissa_cmd_msg
-proc kissa_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!kissa" "kissadb" $unick $uhost $uhand $uchan $utext 1 }
-proc kissa_cmd_msg {unick uhost uhand utext}       { qdb_command "!kissa" "kissadb" $unick $uhost $uhand "" $utext 0 }
+proc kissa_cmd_pub {unick uhost uhand uchan utext} { qdb_cmd "!kissa" "kissadb" $unick $uhost $uhand $uchan $utext 1 }
+proc kissa_cmd_msg {unick uhost uhand utext}       { qdb_cmd "!kissa" "kissadb" $unick $uhost $uhand "" $utext 0 }
 set qdb_messages(kissadb_fmt_get) "kissa @2@ (#@1@)"
 set qdb_messages(kissadb_urlprefix) ""
 set qdb_messages(kissadb_name) "Kissa"
@@ -32,8 +32,8 @@
 
 bind pub - !spede spede_cmd_pub
 bind msg - !spede spede_cmd_msg
-proc spede_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!spede" "spededb" $unick $uhost $uhand $uchan $utext 1 }
-proc spede_cmd_msg {unick uhost uhand utext}       { qdb_command "!spede" "spededb" $unick $uhost $uhand "" $utext 0 }
+proc spede_cmd_pub {unick uhost uhand uchan utext} { qdb_cmd "!spede" "spededb" $unick $uhost $uhand $uchan $utext 1 }
+proc spede_cmd_msg {unick uhost uhand utext}       { qdb_cmd "!spede" "spededb" $unick $uhost $uhand "" $utext 0 }
 set qdb_messages(spededb_urlprefix) "https://tnsp.org/spede/img/"
 set qdb_messages(spededb_name) "Spede"
 set qdb_messages(spededb_stats) "Spede-tilastot: @1@ spedeä, @2@ äänestettyä spedeä."
@@ -42,8 +42,8 @@
 
 bind pub - !mn mn_cmd_pub
 bind msg - !mn mn_cmd_msg
-proc mn_cmd_pub {unick uhost uhand uchan utext}    { qdb_command "!mn" "mndb" $unick $uhost $uhand $uchan $utext 1 }
-proc mn_cmd_msg {unick uhost uhand utext}          { qdb_command "!mn" "mndb" $unick $uhost $uhand "" $utext 0 }
+proc mn_cmd_pub {unick uhost uhand uchan utext}    { qdb_cmd "!mn" "mndb" $unick $uhost $uhand $uchan $utext 1 }
+proc mn_cmd_msg {unick uhost uhand utext}          { qdb_cmd "!mn" "mndb" $unick $uhost $uhand "" $utext 0 }
 set qdb_messages(mndb_urlprefix) "https://tnsp.org/mndb/img/"
 set qdb_messages(mndb_name) "Nykäsismi"
 set qdb_messages(mndb_stats) "Nykäs-tilastot: @1@ nykäsismiä, @2@ äänestettyä."
@@ -52,8 +52,8 @@
 
 bind pub - !tuksu tuksu_cmd_pub
 bind msg - !tuksu tuksu_cmd_msg
-proc tuksu_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!tuksu" "tuksudb" $unick $uhost $uhand $uchan $utext 1 }
-proc tuksu_cmd_msg {unick uhost uhand utext}       { qdb_command "!tuksu" "tuksudb" $unick $uhost $uhand "" $utext 0 }
+proc tuksu_cmd_pub {unick uhost uhand uchan utext} { qdb_cmd "!tuksu" "tuksudb" $unick $uhost $uhand $uchan $utext 1 }
+proc tuksu_cmd_msg {unick uhost uhand utext}       { qdb_cmd "!tuksu" "tuksudb" $unick $uhost $uhand "" $utext 0 }
 set qdb_messages(tuksudb_urlprefix) "https://tnsp.org/tuksu/img/"
 set qdb_messages(tuksudb_name) "Tuksu"
 set qdb_messages(tuksudb_stats) "Tuksu-tilastot: @1@ tuksuilua, @2@ äänestettyä."
--- a/quotedb.tcl	Wed Jul 08 01:47:38 2020 +0300
+++ b/quotedb.tcl	Wed Jul 08 12:12:57 2020 +0300
@@ -448,7 +448,7 @@
 
 
 #-------------------------------------------------------------------------
-proc qdb_command {ucmd utable unick uhost uhand uchan utext upublic} {
+proc qdb_cmd {ucmd utable unick uhost uhand uchan utext upublic} {
   global qdb_channels
 
   # Check if command comes from allowed channel or is private