| 304 | } |
| 305 | |
| 306 | bool strip_suffix(string &s, const string &suffix) |
| 307 | { |
| 308 | if (ends_with(s, suffix)) |
| 309 | { |
| 310 | s.erase(s.length() - suffix.length(), suffix.length()); |
| 311 | trim_string(s); |
| 312 | return true; |
| 313 | } |
| 314 | return false; |
| 315 | } |
| 316 | |
| 317 | string replace_all(string s, const string &find, const string &repl) |
| 318 | { |
no test coverage detected