Skip to content
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

Fixed ###replace: tag that led to incorrect docs #10789

Merged
merged 3 commits into from Nov 24, 2021

Conversation

sss-ng
Copy link
Contributor

@sss-ng sss-ng commented Mar 29, 2021

Fixes

Documentation that is incorrect: before

public Result index() {
       return ok(views.html.index.render("Your new application is
  return ok(javaguide.hello.html.index.render("Your new application is ready.", assetsFinder));
}

According to https://www.playframework.com/documentation/2.8.x/Documentation
###replace: foo — Replace the next line with foo. You may optionally terminate this command with ###

The code sample that was to be run, tested, and injected into the documentation was split into multiple lines (likely by an autoformatter) which made the documentation for the java example incorrect.

This PR changes the 'replace' to one line, and also reduces the whitespace on the left to prevent the autoformatter from splitting the line into two.

Pull Request Checklist

Docs before: https://www.playframework.com/documentation/2.8.x/PlayApplicationOverview: 

```java
public Result index() {
       return ok(views.html.index.render("Your new application is
  return ok(javaguide.hello.html.index.render("Your new application is ready.", assetsFinder));
}
```

According to https://www.playframework.com/documentation/2.8.x/Documentation
```###replace: foo — Replace the next line with foo. You may optionally terminate this command with ###```

The code sample that was to be run, tested, and injected into the documentation was split into multiple lines (likely by an autoformatter) which made the documentation for the java example incorrect. 

This PR changes the 'replace' to one line, and also reduces the whitespace on the left to prevent the autoformatter from splitting the line into two.
Hopefully, the comment has been moved left enough that it won't be split by the formatter. Let's see what the build says
@octonato octonato merged commit 14ecd7d into playframework:2.8.x Nov 24, 2021
@octonato
Copy link
Member

@Mergifyio backport master

@mergify
Copy link
Contributor

mergify bot commented Nov 24, 2021

@octonato is not allowed to run commands

@mkurz
Copy link
Member

mkurz commented Nov 24, 2021

@Mergifyio backport master

@mergify
Copy link
Contributor

mergify bot commented Nov 24, 2021

backport master

✅ Backports have been created

mergify bot added a commit that referenced this pull request Dec 30, 2021
Fixed `###replace:` tag that led to incorrect docs (backport #10789)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants