mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-05-17 03:56:45 +00:00
Fix hardcoded $ in forecast comparison text
Some checks are pending
CI / semgrep (push) Waiting to run
Some checks are pending
CI / semgrep (push) Waiting to run
The "vs last month" line in the forecast section used a hardcoded $ instead of the user's selected currency symbol and rate. Use asCompactCurrency() which handles both. Closes #197
This commit is contained in:
parent
c511627e87
commit
87b660e584
1 changed files with 1 additions and 1 deletions
|
|
@ -515,7 +515,7 @@ private struct ForecastInsight: View {
|
|||
guard previous > 0 else { return "no prior month" }
|
||||
let diff = ((projection - previous) / previous) * 100
|
||||
let sign = diff >= 0 ? "+" : ""
|
||||
return "\(sign)\(String(format: "%.0f", diff))% vs last month ($\(String(format: "%.0f", previous)))"
|
||||
return "\(sign)\(String(format: "%.0f", diff))% vs last month (\(previous.asCompactCurrency()))"
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue