-
Notifications
You must be signed in to change notification settings - Fork 176
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix formatting of code generated by
cargo project new
(#3002)
* Tweak newline locations Remove trailing newline at the end of the file, and separate the imports from the type declarations. * Fix formatting in import Ensure the indentiation follows the convention used in the other files. * Fix import order Order the imports alphabetically so that `cargo clippy` accepts it. * Fix import order in contract template Fix formatting now that the state type has a `State` suffix. * Remove trailing newlines from service template Ensure all files only have one newline at the end of the file. * Add trailing comma to import Ensure it follows proper formatting rules. * Fix whitespace and indentation Remove trailing newlines and spaces, and ensure the code follows the correct indentation standard. * Fix import order Ensure imports are either grouped in alphabetical order or placed in separate paragraphs. * Refactor `handle_query` to remove binding Use a more flow-control style. * Remove unused import The import looks like it's no longer necessary. * Test if template formatting is correct Run `cargo fmt --check` in CI.
- Loading branch information
Showing
5 changed files
with
35 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters