Skip to content

Commit

Permalink
iter9 review fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ex0rcist committed Jul 26, 2024
1 parent 97b8cc9 commit 09ac024
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 5 deletions.
3 changes: 0 additions & 3 deletions internal/storage/file.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"encoding/json"
"fmt"
"os"
"sync"
"time"

"github.com/ex0rcist/metflix/internal/logging"
Expand All @@ -16,7 +15,6 @@ var _ MetricsStorage = (*FileStorage)(nil)

type FileStorage struct {
*MemStorage
sync.Mutex

storePath string
storeInterval int
Expand Down Expand Up @@ -60,7 +58,6 @@ func (s *FileStorage) Push(id string, record Record) error {

func (s *FileStorage) Close() error {
if s.dumpTicker != nil {
fmt.Println("stopping ticker")
s.dumpTicker.Stop()
}

Expand Down
2 changes: 0 additions & 2 deletions internal/storage/file_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package storage

import (
"encoding/json"
"fmt"
"os"
"testing"
"time"
Expand Down Expand Up @@ -56,7 +55,6 @@ func TestSyncPushAndDump(t *testing.T) {

data, err := os.ReadFile(storePath)
checkNoError(t, err, "failed to read storage file")
fmt.Println(string(data))

err = json.Unmarshal(data, &fs.MemStorage)
checkNoError(t, err, "failed to unmarshal storage file")
Expand Down

0 comments on commit 09ac024

Please sign in to comment.