Skip to content

Commit 35fcca2

Browse files
committed
vro.
1 parent 5de440d commit 35fcca2

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

src/Utils.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ void Utils::popualteSongToSongDataMap() {
473473
std::vector<std::string> tempKeys = {};
474474
std::error_code ec, ed;
475475

476-
for (const STRING_TYPE song : songManager.getSongs()) {
476+
for (const std::string_view song : songManager.getSongs()) {
477477
SongType songType = SongType::Regular;
478478
if (std::ranges::find(blacklist.begin(), blacklist.end(), song) != blacklist.end()) songType = SongType::Blacklisted;
479479
else if (std::ranges::find(favorites.begin(), favorites.end(), song) != favorites.end()) songType = SongType::Favorited;
@@ -645,8 +645,8 @@ std::string Utils::toNormalizedString(const std::filesystem::path& path) {
645645
std::filesystem::path Utils::toProblematicString(const std::string_view path) {
646646
#ifdef GEODE_IS_WINDOWS
647647
/* TODO FOR GEODE V5: SWAP COMMENTED LINES */
648-
// return std::filesystem::path(geode::utils::string::utf8ToWide(path).unwrapOr(""));
649-
return std::filesystem::path(geode::utils::string::utf8ToWide(path));
648+
// return std::filesystem::path(geode::utils::string::utf8ToWide(std::string(path)).unwrapOr(""));
649+
return std::filesystem::path(geode::utils::string::utf8ToWide(std::string(path)));
650650
#else
651651
return std::filesystem::path(path);
652652
#endif

src/Utils.hpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
11
#pragma once
22

3-
#ifndef GEODE_IS_WINDOWS
4-
#define STRING_TYPE std::string_view
5-
#else
6-
#define STRING_TYPE std::string&
7-
#endif
8-
93
class Utils {
104
public:
115
static int randomIndex(int);

0 commit comments

Comments
 (0)