We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3839802 commit d4f25c0Copy full SHA for d4f25c0
1 file changed
libs/openFrameworks/utils/ofFileUtils.h
@@ -450,10 +450,11 @@ class ofFilePath {
450
///
451
/// \param strip_debug removes a trailing "Debug" if present
452
/// \returns the App name as native string
453
- static auto getAppName(bool strip_debug = true) {
+ static const auto getAppName(bool strip_debug = true) {
454
auto name = ofFilePath::getCurrentExePathFS().filename().native();
455
+ const std::filesystem::path::string_type debug_suffix = "Debug";
456
if (strip_debug) {
- if (name.size() > 5 && name.compare(name.size() - 5, 5, "Debug") == 0) {
457
+ if (name.size() > 5 && name.compare(name.size() - 5, 5, debug_suffix) == 0) {
458
name.erase(name.size() - 5);
459
}
460
0 commit comments