flush_sessions.go 467 B

1234567891011121314151617181920
  1. // Copyright 2018 Frédéric Guillot. All rights reserved.
  2. // Use of this source code is governed by the Apache 2.0
  3. // license that can be found in the LICENSE file.
  4. package cli // import "miniflux.app/cli"
  5. import (
  6. "fmt"
  7. "os"
  8. "miniflux.app/storage"
  9. )
  10. func flushSessions(store *storage.Storage) {
  11. fmt.Println("Flushing all sessions (disconnect users)")
  12. if err := store.FlushAllSessions(); err != nil {
  13. fmt.Fprintf(os.Stderr, "%v\n", err)
  14. os.Exit(1)
  15. }
  16. }