chore(lint): remove custom min and max functions

These are now available as builtins.
This commit is contained in:
Andrey Nering
2025-03-20 10:42:52 -03:00
parent 76433f7143
commit fff86382cc
8 changed files with 9 additions and 102 deletions
-14
View File
@@ -357,22 +357,8 @@ func (m Model) color(c string) termenv.Color {
return m.colorProfile.Color(c)
}
func max(a, b int) int {
if a > b {
return a
}
return b
}
// IsAnimating returns false if the progress bar reached equilibrium and is no longer animating.
func (m *Model) IsAnimating() bool {
dist := math.Abs(m.percentShown - m.targetPercent)
return !(dist < 0.001 && m.velocity < 0.01)
}
func min(a, b int) int {
if a < b {
return a
}
return b
}