🎭 stay backwards compatible

This commit is contained in:
Fenny
2020-11-18 09:00:59 +01:00
parent ddef41c2ee
commit fd56bd28da
9 changed files with 9 additions and 1 deletions

View File

@@ -18,6 +18,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
// New creates a new memory storage
func New(config ...Config) *Storage {

View File

@@ -21,6 +21,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
// New creates a new storage
func New(config Config) *Storage {

View File

@@ -19,6 +19,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
// New creates a new storage
func New(config ...Config) *Storage {

View File

@@ -17,6 +17,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
type entry struct {
data []byte

View File

@@ -24,6 +24,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
type item struct {
ObjectID primitive.ObjectID `json:"_id,omitempty" bson:"_id,omitempty"`

View File

@@ -26,6 +26,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
var (
dropQuery = "DROP TABLE IF EXISTS %s;"

View File

@@ -24,9 +24,9 @@ type Storage struct {
sqlGC string
}
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
var (
dropQuery = `DROP TABLE IF EXISTS %s;`

View File

@@ -16,6 +16,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
// New creates a new redis storage
func New(config ...Config) *Storage {

View File

@@ -26,6 +26,7 @@ type Storage struct {
// ErrNotFound means that a get call did not find the requested key.
var ErrNotFound = errors.New("key not found")
var ErrKeyNotExist = ErrNotFound
var (
dropQuery = `DROP TABLE IF EXISTS %s;`