Add build::rescore(int score)

main
Simon Quigley 1 week ago
parent 5e6405daa2
commit d7b755c248

@ -94,6 +94,15 @@ bool build::retry() {
return response.has_value();
}
bool build::rescore(int score) {
if (self_link.empty()) return false;
std::map<std::string, std::string> params;
params["ws.op"] = "rescore";
params["score"] = score;
auto response = lp->api_post(self_link, params);
return response.has_value();
}
void build::set_lp(launchpad* lp_ptr) {
lp = lp_ptr;
}

@ -59,6 +59,7 @@ public:
// Methods
bool cancel();
bool retry();
bool rescore(int score);
void set_lp(launchpad* lp_ptr);
// Read-only fields

Loading…
Cancel
Save