mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-12-22 19:01:32 +00:00
Use internal tagging.
This commit is contained in:
parent
46748210ee
commit
4cac67c099
2 changed files with 3 additions and 0 deletions
1
Cargo.lock
generated
1
Cargo.lock
generated
|
@ -2549,6 +2549,7 @@ dependencies = [
|
|||
"lemmy_db_views",
|
||||
"lemmy_db_views_actor",
|
||||
"lemmy_utils",
|
||||
"regex",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"serde_with",
|
||||
|
|
|
@ -282,6 +282,8 @@ pub struct ReportCombinedViewInternal {
|
|||
#[derive(Debug, PartialEq, Serialize, Deserialize, Clone)]
|
||||
#[cfg_attr(feature = "full", derive(TS))]
|
||||
#[cfg_attr(feature = "full", ts(export))]
|
||||
// Use serde's internal tagging, to work easier with javascript libraries
|
||||
#[serde(tag = "type_")]
|
||||
pub enum ReportCombinedView {
|
||||
Post(PostReportView),
|
||||
Comment(CommentReportView),
|
||||
|
|
Loading…
Reference in a new issue