Commit d46c7c6f authored by Jeromy's avatar Jeromy

keytransform datastore doesnt need to implement batching

parent d79a7af4
...@@ -16,8 +16,6 @@ type KeyTransform interface { ...@@ -16,8 +16,6 @@ type KeyTransform interface {
type Datastore interface { type Datastore interface {
ds.Shim ds.Shim
KeyTransform KeyTransform
Batch() (ds.Batch, error)
} }
// Wrap wraps a given datastore with a KeyTransform function. // Wrap wraps a given datastore with a KeyTransform function.
......
...@@ -81,3 +81,11 @@ func (d *datastore) Query(q dsq.Query) (dsq.Results, error) { ...@@ -81,3 +81,11 @@ func (d *datastore) Query(q dsq.Query) (dsq.Results, error) {
return dsq.DerivedResults(qr, ch), nil return dsq.DerivedResults(qr, ch), nil
} }
func (d *datastore) Batch() (ds.Batch, error) {
if bds, ok := d.Datastore.(ds.Batching); ok {
return bds.Batch()
}
return nil, ds.ErrBatchUnsupported
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment