From ee22ec5fd1535d349a67dbd308b2e04f63fd016d Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Sat, 25 May 2024 09:53:51 +0200 Subject: [PATCH] fix build --- backend/windmill-audit/src/audit_ee.rs | 29 +------------------------- backend/windmill-common/src/ee.rs | 6 ------ 2 files changed, 1 insertion(+), 34 deletions(-) diff --git a/backend/windmill-audit/src/audit_ee.rs b/backend/windmill-audit/src/audit_ee.rs index 3520eb10ac..5bb52e7b3f 100644 --- a/backend/windmill-audit/src/audit_ee.rs +++ b/backend/windmill-audit/src/audit_ee.rs @@ -15,37 +15,10 @@ use windmill_common::{ use crate::{ActionKind, AuditLog, ListAuditLogQuery}; use sqlx::{Postgres, Transaction}; -#[derive(Clone)] -pub struct AuditAuthor { - pub username: String, - pub email: String, - pub username_override: Option, -} - -impl AuditAuthorable for AuditAuthor { - fn email(&self) -> &str { - &self.email - } - - fn username(&self) -> &str { - &self.username - } - - fn username_override(&self) -> Option<&str> { - self.username_override.as_deref() - } -} - -pub trait AuditAuthorable { - fn username(&self) -> &str; - fn email(&self) -> &str; - fn username_override(&self) -> Option<&str>; -} - #[tracing::instrument(level = "trace", skip_all)] pub async fn audit_log<'c, E: sqlx::Executor<'c, Database = Postgres>>( _db: E, - _authorable: &impl AuditAuthorable, + _username: &str, mut _operation: &str, _action_kind: ActionKind, _w_id: &str, diff --git a/backend/windmill-common/src/ee.rs b/backend/windmill-common/src/ee.rs index fd9c26e8ed..d3ffd98584 100644 --- a/backend/windmill-common/src/ee.rs +++ b/backend/windmill-common/src/ee.rs @@ -3,9 +3,6 @@ use serde::Deserialize; use std::sync::Arc; use tokio::sync::RwLock; -#[cfg(feature = "enterprise")] -use crate::DB; - lazy_static::lazy_static! { pub static ref LICENSE_KEY_VALID: Arc> = Arc::new(RwLock::new(true)); pub static ref LICENSE_KEY_ID: Arc> = Arc::new(RwLock::new("".to_string())); @@ -28,6 +25,3 @@ pub async fn get_license_plan() -> LicensePlan { pub enum CriticalErrorChannel {} pub async fn trigger_critical_error_channels(_error_message: String) {} - -#[cfg(feature = "enterprise")] -pub async fn schedule_key_renewal(_http_client: &reqwest::Client, _db: &DB) {}