generated from halo-dev/plugin-starter
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: access the list interface without logging in (#81)
#### What type of PR is this? /kind bug #### What this PR does / why we need it: 根据 [自定义 API](https://docs.halo.run/developer-guide/plugin/api-reference/server/extension#%E8%87%AA%E5%AE%9A%E4%B9%89-api) 的规则,当 group 为 `api.<group>` 时,此接口默认为为主题端公开的接口。而 moment 在初始定义时,使用了 `api.plugin.halo.run` 作为 group,因此导致其能被公开访问。 本 pr 将 moment 自定义的接口组由 `api.plugin.halo.run` 改为 `console.api.moment.halo.run`,用于解决用户未登录便可访问瞬间列表的问题。 #### How to test it? 未登录状态下,直接访问接口 `/apis/console.api.moment.halo.run/v1alpha1/moments`。 查看是否提示无权限。 #### Which issue(s) this PR fixes: Fixes #71 #### Does this PR introduce a user-facing change? ```release-note 解决未认证的用户可以获取瞬间列表的问题 ```
- Loading branch information
Showing
5 changed files
with
12 additions
and
14 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