method
This commit is contained in:
parent
158d3aacc8
commit
84deb17e37
@ -118,7 +118,6 @@ func (p *PeerCache) LaunchPeerExecution(peerID string, dataID string,
|
||||
|
||||
// exec executes the method on the peer
|
||||
func (p *PeerCache) exec(url string, method tools.METHOD, body map[string]interface{}, caller *tools.HTTPCaller) error {
|
||||
fmt.Println("exec", url, "...")
|
||||
var b []byte
|
||||
var err error
|
||||
if method == tools.POST { // Execute the POST method if it's a POST method
|
||||
@ -132,7 +131,6 @@ func (p *PeerCache) exec(url string, method tools.METHOD, body map[string]interf
|
||||
}
|
||||
var m map[string]interface{}
|
||||
json.Unmarshal(b, &m)
|
||||
fmt.Printf("Response: %v\n", err)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@ -70,6 +70,7 @@ func (wfa *peerMongoAccessor) Search(filters *dbs.Filters, search string) ([]uti
|
||||
filters = &dbs.Filters{
|
||||
Or: map[string][]dbs.Filter{ // search by name if no filters are provided
|
||||
"abstractobject.name": {{Operator: dbs.LIKE.String(), Value: search}},
|
||||
"url": {{Operator: dbs.LIKE.String(), Value: search}},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user