Skip to content

Commit

Permalink
once_cell::{unsync|sync}::OnceCell -> std::{cell|sync}::{OnceCell|Onc…
Browse files Browse the repository at this point in the history
…eLock}

Summary: codemod: replace `once_cell` with `std`

Reviewed By: lnyng, JakobDegen

Differential Revision: D49776342

fbshipit-source-id: 3f6ca2c1edab61f61b748c1a1c3ffbee872fbf93
  • Loading branch information
Shayne Fletcher authored and facebook-github-bot committed Sep 30, 2023
1 parent d773f7d commit 3293edc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions below/config/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
use std::fs;
use std::path::Path;
use std::path::PathBuf;
use std::sync::OnceLock;

use anyhow::bail;
use anyhow::Result;
use once_cell::sync::OnceCell;
use serde::Deserialize;
use serde::Serialize;

Expand All @@ -30,7 +30,7 @@ const BELOW_DEFAULT_LOG: &str = "/var/log/below";
const BELOW_DEFAULT_STORE: &str = "/var/log/below/store";

/// Global below config
pub static BELOW_CONFIG: OnceCell<BelowConfig> = OnceCell::new();
pub static BELOW_CONFIG: OnceLock<BelowConfig> = OnceLock::new();

#[derive(Serialize, Deserialize, Debug)]
// If value is missing during deserialization, use the Default::default()
Expand Down

0 comments on commit 3293edc

Please sign in to comment.