From 692f9e2951a8bf600f95bb0b76c18df71c881504 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sun, 13 Mar 2016 02:48:32 +0000 Subject: Ignore empty KDM email addresses (#818). --- src/lib/util.cc | 6 ++++++ src/lib/util.h | 1 + 2 files changed, 7 insertions(+) (limited to 'src/lib') diff --git a/src/lib/util.cc b/src/lib/util.cc index 61c9dac06..6f366257c 100644 --- a/src/lib/util.cc +++ b/src/lib/util.cc @@ -636,3 +636,9 @@ relaxed_string_to_float (string s) return lexical_cast (s); } } + +bool +string_not_empty (string s) +{ + return !s.empty (); +} diff --git a/src/lib/util.h b/src/lib/util.h index 640933f00..142b21e96 100644 --- a/src/lib/util.h +++ b/src/lib/util.h @@ -75,5 +75,6 @@ extern std::map split_get_request (std::string url); extern std::string video_asset_filename (boost::shared_ptr asset); extern std::string audio_asset_filename (boost::shared_ptr asset); extern float relaxed_string_to_float (std::string); +extern bool string_not_empty (std::string); #endif -- cgit v1.2.3