From 57eeb6d73b7ac653455645551d14d219ca58c570 Mon Sep 17 00:00:00 2001 From: Miguel Freitas Date: Thu, 7 Nov 2013 17:38:21 -0200 Subject: [PATCH] more hashtags separators and tolower --- src/twister.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/twister.cpp b/src/twister.cpp index d63e1762..6f07e3d4 100644 --- a/src/twister.cpp +++ b/src/twister.cpp @@ -1219,11 +1219,12 @@ Value newpostmsg(const Array& params, bool fHelp) // split and look for mentions and hashtags vector tokens; - boost::algorithm::split(tokens,strMsg,boost::algorithm::is_any_of(" \n\t"), + boost::algorithm::split(tokens,strMsg,boost::algorithm::is_any_of(" \n\t.,:/?!"), boost::algorithm::token_compress_on); BOOST_FOREACH(string const& token, tokens) { if( token.length() >= 2 ) { string word = token.substr(1); + boost::algorithm::to_lower(word); if( token.at(0) == '#') { ses->dht_putData(word, "hashtag", true, v, strUsername, GetAdjustedTime(), 0);