Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove dead impl PluginEncoder for EncodingType #12284

Merged
merged 1 commit into from Mar 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
15 changes: 1 addition & 14 deletions crates/nu-plugin/src/serializers/mod.rs
@@ -1,4 +1,4 @@
use crate::plugin::{Encoder, PluginEncoder};
use crate::plugin::Encoder;
use nu_protocol::ShellError;

pub mod json;
Expand All @@ -22,19 +22,6 @@ impl EncodingType {
_ => None,
}
}

pub fn to_str(&self) -> &'static str {
match self {
Self::Json(_) => "json",
Self::MsgPack(_) => "msgpack",
}
}
}

impl PluginEncoder for EncodingType {
fn name(&self) -> &str {
self.to_str()
}
}

impl<T> Encoder<T> for EncodingType
Expand Down