aboutsummaryrefslogtreecommitdiffstats
path: root/bug/op_set_metadata.go
diff options
context:
space:
mode:
authorMichael Muré <michael.mure@consensys.net>2018-11-21 18:56:12 +0100
committerMichael Muré <batolettre@gmail.com>2019-03-01 22:35:36 +0100
commitfeab9412dffe5772048aad29893c4cb01d566387 (patch)
treeb7bc9751f2ebdf8d41f5621bbf372eaf7625c4b9 /bug/op_set_metadata.go
parent0aefae6fcca5786f2c898029c3d6282f760f2c63 (diff)
downloadgit-bug-feab9412dffe5772048aad29893c4cb01d566387.tar.gz
WIP identity in git
Diffstat (limited to 'bug/op_set_metadata.go')
-rw-r--r--bug/op_set_metadata.go9
1 files changed, 6 insertions, 3 deletions
diff --git a/bug/op_set_metadata.go b/bug/op_set_metadata.go
index aac81f3b..e18f1cb6 100644
--- a/bug/op_set_metadata.go
+++ b/bug/op_set_metadata.go
@@ -1,6 +1,9 @@
package bug
-import "github.com/MichaelMure/git-bug/util/git"
+import (
+ "github.com/MichaelMure/git-bug/identity"
+ "github.com/MichaelMure/git-bug/util/git"
+)
var _ Operation = &SetMetadataOperation{}
@@ -56,7 +59,7 @@ func (op *SetMetadataOperation) Validate() error {
// Sign post method for gqlgen
func (op *SetMetadataOperation) IsAuthored() {}
-func NewSetMetadataOp(author Person, unixTime int64, target git.Hash, newMetadata map[string]string) *SetMetadataOperation {
+func NewSetMetadataOp(author identity.Interface, unixTime int64, target git.Hash, newMetadata map[string]string) *SetMetadataOperation {
return &SetMetadataOperation{
OpBase: newOpBase(SetMetadataOp, author, unixTime),
Target: target,
@@ -65,7 +68,7 @@ func NewSetMetadataOp(author Person, unixTime int64, target git.Hash, newMetadat
}
// Convenience function to apply the operation
-func SetMetadata(b Interface, author Person, unixTime int64, target git.Hash, newMetadata map[string]string) (*SetMetadataOperation, error) {
+func SetMetadata(b Interface, author identity.Interface, unixTime int64, target git.Hash, newMetadata map[string]string) (*SetMetadataOperation, error) {
SetMetadataOp := NewSetMetadataOp(author, unixTime, target, newMetadata)
if err := SetMetadataOp.Validate(); err != nil {
return nil, err