Add fep-e232 feature flag
This commit is contained in:
parent
773c36f3df
commit
1637e38ee4
3 changed files with 10 additions and 3 deletions
|
@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
### Added
|
||||
|
||||
- Added `fep-e232` feature flag (disabled by default).
|
||||
|
||||
## [1.17.0] - 2023-03-15
|
||||
|
||||
### Added
|
||||
|
|
|
@ -97,5 +97,6 @@ serial_test = "0.7.0"
|
|||
|
||||
[features]
|
||||
ethereum-extras = []
|
||||
fep-e232 = []
|
||||
|
||||
production = ["mitra-config/production"]
|
||||
|
|
|
@ -157,15 +157,17 @@ pub fn build_note(
|
|||
assert_eq!(post.links.len(), post.linked.len());
|
||||
for linked in &post.linked {
|
||||
// Build FEP-e232 object link
|
||||
// https://codeberg.org/fediverse/fep/src/branch/main/feps/fep-e232.md
|
||||
let link_href = linked.object_id(instance_url);
|
||||
let _tag = LinkTag {
|
||||
let tag = LinkTag {
|
||||
name: None, // no microsyntax
|
||||
tag_type: LINK.to_string(),
|
||||
href: link_href,
|
||||
media_type: AP_MEDIA_TYPE.to_string(),
|
||||
};
|
||||
// TODO: fix tag processing bug in Pleroma
|
||||
// tags.push(Tag::LinkTag(tag));
|
||||
if cfg!(feature = "fep-e232") {
|
||||
tags.push(Tag::LinkTag(tag));
|
||||
};
|
||||
};
|
||||
let maybe_quote_url = post.linked.get(0)
|
||||
.map(|linked| linked.object_id(instance_url));
|
||||
|
|
Loading…
Reference in a new issue