Skip to content

Make callback example link relative #1223

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

Merged
merged 1 commit into from
Jun 30, 2017

Conversation

MikeRalphson
Copy link
Member

Saves having to remember to update it later.

versions/3.0.md Outdated
@@ -1820,7 +1820,7 @@ The key value used to identify the callback object is an expression, evaluated a
##### Patterned Fields
Field Pattern | Type | Description
---|:---:|---
<a name="callbackExpression"></a>{expression} | [Path Item Object](#pathItemObject) | A Path Item Object used to define a callback request and expected responses. A [complete example](https://github.com/OAI/OpenAPI-Specification/blob/OpenAPI.next/examples/v3.0/callback-example.yaml) is available.
<a name="callbackExpression"></a>{expression} | [Path Item Object](#pathItemObject) | A Path Item Object used to define a callback request and expected responses. A [complete example](/examples/v3.0/callback-example.yaml) is available.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't that need a .. at the front of that URL?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems to work ok in my fork, i.e. it's a repo-root relative url.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the difference is that with the .. it points to the example in the current branch, without it points to master (where this file doesn't exist yet).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The link in my fork points to https://github.com/OAI/OpenAPI-Specification/blob/OpenAPI.next/examples/v3.0/callback-example.yaml - not the master branch? Viewing the changes I see a link to the commit blob

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I looked at it in the differences view, and there it pointed to https://github.com/OAI/OpenAPI-Specification/blob/master/examples/v3.0/callback-example.yaml. Strangely, if I open the same address again in a new browser tab, it now points to https://github.com/OAI/OpenAPI-Specification/blob/rel_link/examples/v3.0/callback-example.yaml. (Both links give 404s currently, the second one uses your branch name with the main fork's repository name.)

I guess Github it not that predictable with the link expansion.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ePaul for looking at it again. Let's try it with the ..

@RobDolinMS RobDolinMS merged commit 310e0bd into OAI:OpenAPI.next Jun 30, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants