summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbladictionary.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/bladictionary.py b/bladictionary.py
index 932d54e..edfd250 100755
--- a/bladictionary.py
+++ b/bladictionary.py
@@ -9,7 +9,7 @@ import sqlite3
import requests
from definition import Definition
-VERSION = "2.4.1"
+VERSION = "2.4.2"
def get_xml(word, word_dict):
api_url = "http://services.aonaware.com/DictService/DictService.asmx/DefineInDict?dictId="+word_dict+"&word="+word
@@ -384,10 +384,11 @@ def main():
#Length limit for IRC messages
#RFC specifies message length is 510. This includes protocol stuff.
#37 is for the user/hostname of Bratchbot, then take off the length of the channel name
+ #Actually this isn't right and 412 seems to work
if options.channel:
- max_length = 510 - 37 - len(options.channel)
+ max_length = 412 - len(options.channel)
else:
- max_length = 460
+ max_length = 400
types = ["n", "v", "adj", "adv", "tech", "urban"]
type_id = 0
@@ -480,4 +481,4 @@ def main():
print "(" + str(num_more) + " more)"
if __name__ == "__main__":
- main() \ No newline at end of file
+ main()