Skip to content

Commit 5b70692

Browse files
committed
fix doc links
1 parent d1bfc68 commit 5b70692

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

src/metadata.rs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ pub struct Metadata {
4848
/// recipe between different cooklang applications. You can read more about it
4949
/// in [the spec](https://cooklang.org/docs/spec/#canonical-metadata).
5050
///
51-
/// To use them, use [`Metadata::get_std`].
51+
/// To use them, use [`Metadata::get`].
5252
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
5353
#[serde(rename_all = "snake_case")]
5454
pub enum StdKey {
@@ -171,7 +171,7 @@ impl Metadata {
171171
///
172172
/// This *who* wrote the recipe.
173173
///
174-
/// The `author` key [`as_name_and_url`](CooklangValueExt::as_value_and_url).
174+
/// The `author` key [`as_name_and_url`](CooklangValueExt::as_name_and_url).
175175
pub fn author(&self) -> Option<NameAndUrl> {
176176
self.get(StdKey::Author)
177177
.and_then(CooklangValueExt::as_name_and_url)
@@ -181,7 +181,7 @@ impl Metadata {
181181
///
182182
/// This *where* the recipe was obtained from.
183183
///
184-
/// The `source` key [`as_name_and_url`](CooklangValueExt::as_value_and_url).
184+
/// The `source` key [`as_name_and_url`](CooklangValueExt::as_name_and_url).
185185
pub fn source(&self) -> Option<NameAndUrl> {
186186
self.get(StdKey::Source)
187187
.and_then(CooklangValueExt::as_name_and_url)
@@ -338,8 +338,9 @@ pub trait CooklangValueExt: private::Sealed {
338338

339339
/// Get a [`RecipeTime`]
340340
///
341-
/// This can be a single number or string like in [`as_minutes`] or a mapping
342-
/// of `prep_time` and `cook_time` where each of them is a number or string.
341+
/// This can be a single number or string like in
342+
/// [`as_minutes`](CooklangValueExt::as_minutes) or a mapping of `prep_time`
343+
/// and `cook_time` where each of them is a number or string.
343344
fn as_time(&self, converter: &Converter) -> Option<RecipeTime>;
344345

345346
/// Like [`serde_yaml::Value::as_u64`] but ensuring the value fits in a u32

src/scale.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ impl ScalableRecipe {
384384
/// Get the defined number of servings in the recipe
385385
///
386386
/// This is set automatically from the metadata. To change it manually use
387-
/// [`set_servings`].
387+
/// [`set_servings`](ScalableRecipe::set_servings).
388388
pub fn servings(&self) -> Option<&[u32]> {
389389
if let Servings(Some(s)) = &self.data {
390390
Some(s.as_slice())

0 commit comments

Comments
 (0)