json+ld; profile, not json+ld; context

This commit is contained in:
asonix 2020-04-21 19:24:23 -05:00
parent 33fd061a8a
commit 44cf59a8ea
3 changed files with 5 additions and 5 deletions

View file

@ -1,7 +1,7 @@
[package] [package]
name = "actix-webfinger" name = "actix-webfinger"
description = "Types and helpers to create and fetch Webfinger resources" description = "Types and helpers to create and fetch Webfinger resources"
version = "0.3.0-alpha.5" version = "0.3.0-alpha.6"
license = "GPL-3.0" license = "GPL-3.0"
authors = ["asonix <asonix@asonix.dog>"] authors = ["asonix <asonix@asonix.dog>"]
repository = "https://git.asonix.dog/Aardwolf/actix-webfinger" repository = "https://git.asonix.dog/Aardwolf/actix-webfinger"

View file

@ -13,9 +13,9 @@ First, add Actix Webfinger as a dependency
```toml ```toml
[dependencies] [dependencies]
actix = "0.10.0-alpha.1" actix-rt = "0.10.0-alpha.2"
actix-web = "3.0.0-alpha.1" actix-web = "3.0.0-alpha.1"
actix-webfinger = "0.3.0-alpha.5" actix-webfinger = "0.3.0-alpha.6"
``` ```
Then use it in your application Then use it in your application

View file

@ -476,10 +476,10 @@ impl Webfinger {
} }
/// Add a JsonLD Link to this Webfinger /// Add a JsonLD Link to this Webfinger
pub fn add_json_ld(&mut self, href: &str, context: &str) -> &mut Self { pub fn add_json_ld(&mut self, href: &str, profile: &str) -> &mut Self {
self.links.push(Link { self.links.push(Link {
rel: "self".to_owned(), rel: "self".to_owned(),
kind: Some(format!("application/ld+json; context=\"{}\"", context)), kind: Some(format!("application/ld+json; profile=\"{}\"", profile)),
href: Some(href.to_owned()), href: Some(href.to_owned()),
template: None, template: None,
}); });