forked from github-starred/komodo
update update after build clone
This commit is contained in:
@@ -8,7 +8,7 @@ use serde::{Deserialize, Serialize};
|
||||
use strum_macros::{Display, EnumString};
|
||||
use typeshare::typeshare;
|
||||
|
||||
use crate::{entities::Operation, monitor_timestamp, MongoId, I64};
|
||||
use crate::{entities::Operation, monitor_timestamp, MongoId, I64, all_logs_success};
|
||||
|
||||
use super::{
|
||||
alerter::Alerter, build::Build, builder::Builder, deployment::Deployment, repo::Repo,
|
||||
@@ -56,15 +56,6 @@ impl Update {
|
||||
}
|
||||
}
|
||||
|
||||
fn all_logs_success(logs: &Vec<Log>) -> bool {
|
||||
for log in logs {
|
||||
if !log.success {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
true
|
||||
}
|
||||
|
||||
#[typeshare]
|
||||
#[derive(Serialize, Deserialize, Debug, Clone, Default)]
|
||||
pub struct Log {
|
||||
|
||||
@@ -27,7 +27,7 @@ pub struct MongoIdObj {
|
||||
pub oid: String,
|
||||
}
|
||||
|
||||
pub fn all_logs_success(logs: &Vec<Log>) -> bool {
|
||||
pub fn all_logs_success(logs: &[Log]) -> bool {
|
||||
for log in logs {
|
||||
if !log.success {
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user