fix api
This commit is contained in:
parent
56fefbe52d
commit
1133e00ccc
@ -43,8 +43,8 @@ pub struct ScriptPolicyHashRequest{
|
||||
#[derive(serde::Deserialize)]
|
||||
pub struct ScriptPolicyResponse{
|
||||
pub ID:i64,
|
||||
pub Hash:String,
|
||||
pub ScriptID:ScriptID,
|
||||
pub FromScriptHash:String,
|
||||
pub ToScriptID:ScriptID,
|
||||
pub Policy:Policy
|
||||
}
|
||||
|
||||
|
@ -122,7 +122,7 @@ impl Validator{
|
||||
api::Policy::Delete=>Policy::Delete,
|
||||
api::Policy::Replace=>{
|
||||
let script=self.api.get_script(api::GetScriptRequest{
|
||||
ScriptID:script_policy.ScriptID,
|
||||
ScriptID:script_policy.ToScriptID,
|
||||
}).await.map_err(ValidateError::ApiGetScript)?;
|
||||
Policy::Replace(script.Source)
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user