aboutsummaryrefslogtreecommitdiff
path: root/steam/game.go
diff options
context:
space:
mode:
Diffstat (limited to 'steam/game.go')
-rw-r--r--steam/game.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/steam/game.go b/steam/game.go
index 0028257..dd4a297 100644
--- a/steam/game.go
+++ b/steam/game.go
@@ -5,6 +5,15 @@ import (
"path/filepath"
)
+// GetSizeBytes returns the size in bytes, calling SetSizeInfo info Size is
+// currently == 0
+func (g *Game) GetSizeBytes() int64 {
+ if g.Size == 0 {
+ _ = g.SetSizeInfo()
+ }
+ return g.Size
+}
+
// GetSize returns the size of a game in a pretty format. If size is 0
// it will call SetSizeInfo before returning
func (g *Game) GetSize() string {