Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 22 additions & 4 deletions Cherrish-iOS/Cherrish-iOS.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
objects = {

/* Begin PBXFileReference section */
5126F89E2F0E9AF000E67E33 /* OSLog.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OSLog.framework; path = System/Library/Frameworks/OSLog.framework; sourceTree = SDKROOT; };
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿงน Nitpick | ๐Ÿ”ต Trivial

OSLog.framework ๋ช…์‹œ์  ๋งํฌ๊ฐ€ ๋ถˆํ•„์š”ํ•ฉ๋‹ˆ๋‹ค.

OSLog๋Š” iOS 10๋ถ€ํ„ฐ ์‚ฌ์šฉ ๊ฐ€๋Šฅํ•œ ์‹œ์Šคํ…œ ํ”„๋ ˆ์ž„์›Œํฌ๋กœ, import OSLog๋งŒ์œผ๋กœ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ํ”„๋กœ์ ํŠธ์— ๋ช…์‹œ์ ์œผ๋กœ ๋งํฌํ•  ํ•„์š”๊ฐ€ ์—†์œผ๋ฉฐ, ์ด ์ฐธ์กฐ์™€ ๊ด€๋ จ๋œ Frameworks ๊ทธ๋ฃน(lines 46-53)์„ ์ œ๊ฑฐํ•ด๋„ ๋ฉ๋‹ˆ๋‹ค.

๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS.xcodeproj/project.pbxproj at line 10, The PBX file
contains an explicit PBXFileReference for OSLog.framework (the entry with name =
OSLog.framework and path = System/Library/Frameworks/OSLog.framework) and an
associated Frameworks group that are unnecessary; remove that PBXFileReference
and any references to the Frameworks group (the Frameworks group block that
lists OSLog.framework and related entries) from the project.pbxproj so OSLog is
used via import OSLog only and not explicitly linked in the project.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

์ง€์› ๋Š”๋ฐ..;;

51B5D3182F0514390090B8B4 /* Cherrish-iOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Cherrish-iOS.app"; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */

Expand Down Expand Up @@ -42,10 +43,19 @@
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
5126F89D2F0E9AF000E67E33 /* Frameworks */ = {
isa = PBXGroup;
children = (
5126F89E2F0E9AF000E67E33 /* OSLog.framework */,
);
name = Frameworks;
sourceTree = "<group>";
};
51B5D30F2F0514390090B8B4 = {
isa = PBXGroup;
children = (
51B5D31A2F0514390090B8B4 /* Cherrish-iOS */,
5126F89D2F0E9AF000E67E33 /* Frameworks */,
51B5D3192F0514390090B8B4 /* Products */,
);
sourceTree = "<group>";
Expand Down Expand Up @@ -262,10 +272,12 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Manual;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = CG37U6CMKP;
DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = CG37U6CMKP;
ENABLE_PREVIEWS = YES;
Comment on lines +275 to 281
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿงน Nitpick | ๐Ÿ”ต Trivial

์ˆ˜๋™ ์ฝ”๋“œ ์„œ๋ช… ์„ค์ •์„ ํ™•์ธํ•˜์„ธ์š”.

์ฝ”๋“œ ์„œ๋ช… ๋ฐฉ์‹์ด Automatic์—์„œ Manual๋กœ ๋ณ€๊ฒฝ๋˜์—ˆ๊ณ , ๊ฐœ๋ฐœ ํŒ€ ๋ฐ ํ”„๋กœ๋น„์ €๋‹ ํ”„๋กœํŒŒ์ผ์ด ์„ค์ •๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ์ด๋Ÿฌํ•œ ๋ณ€๊ฒฝ์‚ฌํ•ญ์€:

  • ๋‹ค๋ฅธ ํŒ€ ๋ฉค๋ฒ„๋“ค์˜ ๋กœ์ปฌ ๋นŒ๋“œ์— ์˜ํ–ฅ์„ ์ค„ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค
  • CI/CD ํŒŒ์ดํ”„๋ผ์ธ ์„ค์ •๊ณผ ์ผ์น˜ํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค
  • ํ”„๋กœ๋น„์ €๋‹ ํ”„๋กœํŒŒ์ผ(cherrish-development)์ด ๋ชจ๋“  ๊ฐœ๋ฐœ์ž์˜ Xcode์— ์„ค์น˜๋˜์–ด ์žˆ์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค

ํŒ€ ์ „์ฒด๊ฐ€ ๋™์ผํ•œ ํ”„๋กœ๋น„์ €๋‹ ํ”„๋กœํŒŒ์ผ๊ณผ ์ธ์ฆ์„œ์— ์•ก์„ธ์Šคํ•  ์ˆ˜ ์žˆ๋Š”์ง€ ํ™•์ธํ•˜์„ธ์š”.

Also applies to: 302-303

๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS.xcodeproj/project.pbxproj around lines 280 - 286,
The project file now forces manual signing (CODE_SIGN_STYLE = Manual) and sets
specific signing keys (CODE_SIGN_IDENTITY[sdk=iphoneos*], DEVELOPMENT_TEAM,
"DEVELOPMENT_TEAM[sdk=iphoneos*]") and development asset paths; revert to a
team-agnostic, CI-friendly setup by either restoring CODE_SIGN_STYLE = Automatic
and clearing DEVELOPMENT_TEAM/PROVISIONING entries or, if manual signing is
required, document and commit instructions to ensure every developer and CI has
the named provisioning profile (cherrish-development) and certificate installed;
update project.pbxproj to remove hardcoded team IDs and provisioning settings or
add commentary for maintainers and then verify by producing a short confirmation
that the change allows other devs and CI to build ([request_verification]).

GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "Cherrish-iOS/Info.plist";
Expand All @@ -282,6 +294,8 @@
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = "com.nayeon.Cherrish-iOS";
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "cherrish-development";
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
Expand All @@ -293,10 +307,12 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = CG37U6CMKP;
DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = CG37U6CMKP;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "Cherrish-iOS/Info.plist";
Expand All @@ -313,6 +329,8 @@
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = "com.nayeon.Cherrish-iOS";
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "cherrish-distribution";
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down
43 changes: 43 additions & 0 deletions Cherrish-iOS/Cherrish-iOS/Core/CherrishError.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
//
// CherrishError.swift
// Cherrish-iOS
//
// Created by ์ด๋‚˜์—ฐ on 1/8/26.
//

import Foundation

enum CherrishError: Error, LocalizedError, Equatable {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿ› ๏ธ Refactor suggestion | ๐ŸŸ  Major

์ ‘๊ทผ ์ œ์–ด์ž๋ฅผ ๋ช…์‹œํ•˜์„ธ์š”.

์ด ์—๋Ÿฌ ํƒ€์ž…์ด ํ”„๋กœ์ ํŠธ ์ „์ฒด์—์„œ ์‚ฌ์šฉ๋  ๊ฒƒ์œผ๋กœ ๋ณด์ด๋ฏ€๋กœ, public enum CherrishError๋กœ ๋ช…์‹œ์ ์œผ๋กœ ์„ ์–ธํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค. ํ˜„์žฌ ์•”์‹œ์  internal ์ ‘๊ทผ ์ œ์–ด๋Š” ๋ชจ๋“ˆ ์™ธ๋ถ€์—์„œ ์‚ฌ์šฉํ•  ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.

โ™ป๏ธ ์ œ์•ˆํ•˜๋Š” ์ˆ˜์ •
-enum CherrishError: Error, LocalizedError, Equatable {
+public enum CherrishError: Error, LocalizedError, Equatable {
๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS/Core/CherrishError.swift at line 10, The enum
CherrishError is implicitly internal but should be exported; change its
declaration from "enum CherrishError: Error, LocalizedError, Equatable" to
"public enum CherrishError: Error, LocalizedError, Equatable" so the type (and
any public cases or members) is usable outside the module, and update any nested
members or associated values to appropriate access levels if needed.

case DIFailedError
case decodingError
case URLError
case networkRequestFailed
case networkConnect
case networkError(code: Int, message: String)
case noData
case unknownError
case encodingError
Comment on lines +10 to +19
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿ› ๏ธ Refactor suggestion | ๐ŸŸ  Major

์ ‘๊ทผ ์ œ์–ด์ž๋ฅผ ๋ช…์‹œํ•˜์„ธ์š”.

์ด ์—๋Ÿฌ ํƒ€์ž…์ด ํ”„๋กœ์ ํŠธ ์ „์ฒด์—์„œ ์‚ฌ์šฉ๋  ๊ฒƒ์œผ๋กœ ๋ณด์ด๋ฏ€๋กœ, public enum CherrishError๋กœ ๋ช…์‹œ์ ์œผ๋กœ ์„ ์–ธํ•˜๋Š” ๊ฒƒ์ด ์ข‹์Šต๋‹ˆ๋‹ค.

โ™ป๏ธ ์ œ์•ˆํ•˜๋Š” ์ˆ˜์ •
-enum CherrishError: Error, LocalizedError, Equatable {
+public enum CherrishError: Error, LocalizedError, Equatable {
๐Ÿ“ Committable suggestion

โ€ผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
enum CherrishError: Error, LocalizedError, Equatable {
case DIFailedError
case decodingError
case URLError
case networkRequestFailed
case networkConnect
case networkError(code: Int, message: String)
case noData
case unknownError
case encodingError
public enum CherrishError: Error, LocalizedError, Equatable {
case DIFailedError
case decodingError
case URLError
case networkRequestFailed
case networkConnect
case networkError(code: Int, message: String)
case noData
case unknownError
case encodingError
๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS/Core/CherrishError.swift around lines 10 - 19, The
enum CherrishError should be explicitly exported: change the declaration of
CherrishError to be public so it can be used across the project (i.e., make the
type public by updating the declaration for enum CherrishError to include the
public access modifier while keeping its existing cases like DIFailedError,
decodingError, URLError, networkRequestFailed, networkConnect,
networkError(code:message:), noData, unknownError, and encodingError).


var errorDescription: String? {
switch self {
case .DIFailedError:
return "์˜์กด์„ฑ ์ฃผ์ž… ์‹คํŒจ"
case .decodingError:
return "๋””์ฝ”๋”ฉ ์‹คํŒจ"
case .URLError:
return "URL ๋ณ€ํ™˜ ์‹คํŒจ"
case .networkRequestFailed:
return "๋„คํŠธ์›Œํฌ ์š”์ฒญ ์‹คํŒจ"
case .networkConnect:
return "๋„คํŠธ์›Œํฌ ์—ฐ๊ฒฐ ์—๋Ÿฌ"
case .networkError(let code, let message):
return "\(code): \(message)"
case .noData:
return "๋ฐ์ดํ„ฐ ์—†์Œ"
case .encodingError:
return "์ธ์ฝ”๋”ฉ ์‹คํŒจ"
case .unknownError:
return "์•Œ ์ˆ˜ ์—†๋Š” ์˜ค๋ฅ˜"
}
}
}
147 changes: 147 additions & 0 deletions Cherrish-iOS/Cherrish-iOS/Core/CherrishLogger.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,150 @@
// Created by ์ด๋‚˜์—ฐ on 12/31/25.
//

import OSLog

extension OSLog {
static let subsystem = Bundle.main.bundleIdentifier!
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

โš ๏ธ Potential issue | ๐ŸŸ  Major

bundleIdentifier ๊ฐ•์ œ ์–ธ๋ž˜ํ•‘์ด ์œ„ํ—˜ํ•ฉ๋‹ˆ๋‹ค.

Bundle.main.bundleIdentifier!๋Š” ์œ ๋‹› ํ…Œ์ŠคํŠธ๋‚˜ ํŠน์ • ํ™˜๊ฒฝ์—์„œ ํฌ๋ž˜์‹œ๋ฅผ ๋ฐœ์ƒ์‹œํ‚ฌ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

๐Ÿ”’ ์ œ์•ˆํ•˜๋Š” ์ˆ˜์ •
-    static let subsystem = Bundle.main.bundleIdentifier!
+    static let subsystem = Bundle.main.bundleIdentifier ?? "com.cherrish.unknown"
๐Ÿ“ Committable suggestion

โ€ผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
static let subsystem = Bundle.main.bundleIdentifier!
static let subsystem = Bundle.main.bundleIdentifier ?? "com.cherrish.unknown"
๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS/Core/CherrishLogger.swift at line 11, The forced
unwrap of Bundle.main.bundleIdentifier in the static let subsystem constant is
unsafe and can crash in tests or certain environments; change the initializer
for subsystem in CherrishLogger (static let subsystem) to handle the optional
safely โ€” e.g., use nil-coalescing to a sensible default identifier or fallback
to another safe source (Bundle.main.object(forInfoDictionaryKey:
"CFBundleIdentifier") as? String ?? "com.cherrish.unknown"), or compute it
lazily and guard-fail with a default, so no forced unwrap remains.

static let network = OSLog(subsystem: subsystem, category: "Network")
static let debug = OSLog(subsystem: subsystem, category: "Debug")
static let data = OSLog(subsystem: subsystem, category: "Data")
static let error = OSLog(subsystem: subsystem, category: "Error")
}

enum LogType {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿ› ๏ธ Refactor suggestion | ๐ŸŸ  Major

LogType๊ณผ CherrishLogger์˜ ์ ‘๊ทผ ์ œ์–ด์ž๋ฅผ ๋ช…์‹œํ•˜์„ธ์š”.

์ด ํƒ€์ž…๋“ค์ด ํ”„๋กœ์ ํŠธ ์ „์ฒด์—์„œ ์‚ฌ์šฉ๋˜๋ฏ€๋กœ public์œผ๋กœ ์„ ์–ธํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ํ˜„์žฌ ์•”์‹œ์  internal ์ ‘๊ทผ ์ œ์–ด๋Š” ๋ชจ๋“ˆ ์™ธ๋ถ€์—์„œ ์‚ฌ์šฉํ•  ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.

โ™ป๏ธ ์ œ์•ˆํ•˜๋Š” ์ˆ˜์ •
-enum LogType {
+public enum LogType {
     case network
     case debug
     case data
     case error(error: Error)
     // ...
 }

-struct CherrishLogger {
+public struct CherrishLogger {
     // ...
 }

Also applies to: 71-71

๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS/Core/CherrishLogger.swift at line 18, LogType and
CherrishLogger are currently implicitly internal and need to be usable across
the module boundary; change their declarations to public by adding the public
access modifier to the enum LogType and the CherrishLogger type (and any related
declarations at the other occurrence referenced) so they are exported from the
module; ensure any methods, initializers, or nested types that must be accessed
externally are also marked public as needed.

case network
case debug
case data
case error(error: Error)

var category: String {
switch self {
case .network:
return "Network"
case .debug:
return "Debug"
case .data:
return "Data"
case .error:
return "Error"
}
}

var osLog: OSLog {
switch self {
case .network:
return OSLog.network
case .debug:
return OSLog.debug
case .data:
return OSLog.data
case .error:
return OSLog.error
}
}

var osLogType: OSLogType {
switch self {
case .network, .data:
return .default
case .debug:
return .debug
case .error:
return .error
}
}

var shouldShowLogInRelease: Bool {
switch self {
case .error:
true
default:
false
}
}
}

struct CherrishLogger {
private static var isDebugMode: Bool {
#if DEBUG
return true
#else
return false
#endif
}

private static func shouldShowLog(type: LogType) -> Bool {
if isDebugMode { return true }

return type.shouldShowLogInRelease
}

private static let dateFormatter: DateFormatter = {
let formatter = DateFormatter()
formatter.dateFormat = "yyyy/MM/dd HH:mm:ss"
formatter.locale = Locale(identifier: "en_US_POSIX")
return formatter
}()

private static var timestamp: String {
dateFormatter.string(from: Date())
}

static private func log(
type: LogType,
message: Any,
file: String,
function: String

) {
guard shouldShowLog(type: type) else { return }

let logger = Logger(subsystem: OSLog.subsystem, category: type.category)
let logMessage = "\(message)"
let fileName = (file as NSString).lastPathComponent

switch type {
case .network:
logger.log("[๐Ÿ›œ Network] [Date: \(timestamp)] [\(fileName) -> \(function)]: \(logMessage)")
case .debug:
logger.debug("[๐Ÿ› Debug] [Date: \(timestamp)] [\(fileName) -> \(function)]: \(logMessage)")
case .data:
logger.info("[๐Ÿ“Š Data] [Date: \(timestamp)] [\(fileName) -> \(function)]: \(logMessage)")
case .error(let error):
logger.error("[โŒ Error] [Date: \(timestamp)] [\(fileName) -> \(function)]: \(error.localizedDescription)")

}
}

static func network(
_ message: Any,
file: String = #file,
function: String = #function
) {
log(type: .network, message: message, file: file, function: function)
}

static func debug(
_ message: Any,
file: String = #file,
function: String = #function
) {
log(type: .debug, message: message, file: file, function: function)
}

static func data(
_ message: Any,
file: String = #file,
function: String = #function
) {
log(type: .data, message: message, file: file, function: function)
}

static func error(
_ error: Error,
file: String = #file,
function: String = #function
) {
log(type: .error(error: error), message: "", file: file, function: function)
}
Comment on lines +147 to +153
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿงน Nitpick | ๐Ÿ”ต Trivial

error ํ•จ์ˆ˜์˜ message ํŒŒ๋ผ๋ฏธํ„ฐ ์‚ฌ์šฉ์„ ๊ณ ๋ คํ•˜์„ธ์š”.

ํ˜„์žฌ error ํ•จ์ˆ˜๋Š” ๋นˆ ๋ฌธ์ž์—ด("")์„ message๋กœ ์ „๋‹ฌํ•˜๊ณ , ๋‚ด๋ถ€์ ์œผ๋กœ error.localizedDescription๋งŒ ๋กœ๊น…ํ•ฉ๋‹ˆ๋‹ค. ์ถ”๊ฐ€ ์ปจํ…์ŠคํŠธ ๋ฉ”์‹œ์ง€๋ฅผ ํ•จ๊ป˜ ๊ธฐ๋กํ•  ์ˆ˜ ์žˆ๋„๋ก ํŒŒ๋ผ๋ฏธํ„ฐ๋ฅผ ํ™•์žฅํ•˜๋Š” ๊ฒƒ์„ ๊ณ ๋ คํ•ด๋ณด์„ธ์š”.

โ™ป๏ธ ์ œ์•ˆํ•˜๋Š” ์ˆ˜์ •
     static func error(
         _ error: Error,
+        message: Any = "",
         file: String = #file,
         function: String = #function
     ) {
-        log(type: .error(error: error), message: "", file: file, function: function)
+        log(type: .error(error: error), message: message, file: file, function: function)
     }

๊ทธ๋ฆฌ๊ณ  log ํ•จ์ˆ˜ ๋‚ด error ์ผ€์ด์Šค์—์„œ:

         case .error(let error):
-            logger.error("[โŒ Error] [Date: \(timestamp)] [\(fileName) -> \(function)]: \(error.localizedDescription)")
+            let contextMessage = logMessage.isEmpty ? "" : "[\(logMessage)] "
+            logger.error("[โŒ Error] [Date: \(timestamp)] [\(fileName) -> \(function)]: \(contextMessage)\(error.localizedDescription)")

Committable suggestion skipped: line range outside the PR's diff.

๐Ÿค– Prompt for AI Agents
In @Cherrish-iOS/Cherrish-iOS/Core/CherrishLogger.swift around lines 147 - 153,
Change the static func error to accept an optional message parameter (e.g.,
message: String = "") and pass that message into the existing log call instead
of the empty string; update the log handling for the .error(error: Error) case
inside log(...) to include and format both the provided message and
error.localizedDescription (so the log output shows the custom context message
plus the error details). Ensure you update the signature of CherrishLogger.error
and the .error case handling code paths that construct the final log string.

}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@ final class TestViewModel: ObservableObject {
func test() {
testUseCase.execute()
text = "๋ฒ„ํŠผ ํ„ฐ์น˜ํ–ˆ์Œ!"
print("view model execute")
CherrishLogger.debug("๋กœ๊ฑฐ ํ…Œ์ŠคํŠธ")
}
}