mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-30 01:27:31 +08:00
chore: add lints in workspace cargo config (#223)
This commit is contained in:
@ -63,7 +63,7 @@ pub fn workspace_path() -> PathBuf {
|
||||
// for (key, value) in std::env::vars() {
|
||||
// println!("{key} : {value}");
|
||||
// }
|
||||
if let Result::Ok(manifest_dir) = std::env::var(CARGO_MANIFEST_DIR) {
|
||||
if let Ok(manifest_dir) = std::env::var(CARGO_MANIFEST_DIR) {
|
||||
let mut path = PathBuf::from(manifest_dir);
|
||||
path.pop();
|
||||
path.pop();
|
||||
|
||||
@ -1,17 +1,5 @@
|
||||
#![forbid(unsafe_code)]
|
||||
#![warn(
|
||||
missing_docs,
|
||||
rust_2018_idioms,
|
||||
missing_debug_implementations,
|
||||
clippy::expect_used,
|
||||
clippy::missing_panics_doc,
|
||||
clippy::panic,
|
||||
clippy::panic_in_result_fn,
|
||||
clippy::panicking_unwrap,
|
||||
clippy::unreachable,
|
||||
clippy::unwrap_in_result,
|
||||
clippy::unwrap_used
|
||||
)]
|
||||
#![warn(missing_docs, missing_debug_implementations)]
|
||||
|
||||
//!
|
||||
//! Environment of payment router: logger, basic config, its environment awareness.
|
||||
|
||||
@ -102,9 +102,9 @@ pub enum RecordType {
|
||||
impl fmt::Display for RecordType {
|
||||
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
let repr = match self {
|
||||
RecordType::EnterSpan => "START",
|
||||
RecordType::ExitSpan => "END",
|
||||
RecordType::Event => "EVENT",
|
||||
Self::EnterSpan => "START",
|
||||
Self::ExitSpan => "END",
|
||||
Self::Event => "EVENT",
|
||||
};
|
||||
write!(f, "{}", repr)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user