You've already forked pages
forked from didirus/AstralRinth
Housekeeping + Fix DB perf issues (#542)
* Housekeeping + fix db perf issues * run prep
This commit is contained in:
@@ -108,11 +108,13 @@ pub async fn process_payout(
|
||||
pool: web::Data<PgPool>,
|
||||
data: web::Json<PayoutData>,
|
||||
) -> Result<HttpResponse, ApiError> {
|
||||
let start = data
|
||||
.date
|
||||
.date()
|
||||
.and_hms_nano(0, 0, 0, 0)
|
||||
.with_timezone(&Utc);
|
||||
let start: DateTime<Utc> = DateTime::from_utc(
|
||||
data.date
|
||||
.date_naive()
|
||||
.and_hms_nano_opt(0, 0, 0, 0)
|
||||
.unwrap_or_default(),
|
||||
Utc,
|
||||
);
|
||||
|
||||
let client = reqwest::Client::new();
|
||||
let mut transaction = pool.begin().await?;
|
||||
|
||||
Reference in New Issue
Block a user