AppFlowy-IO / AppFlowy-IO/AppFlowy-Web
[Bug] Refactor this function to not always return the same value.
- 主要语言
- TypeScript
- 星标
- 326
- 派生
- 167
- 平均合并
- 17 小时 6 分钟
- 30 天内合并 PR
- 72
描述
### Bug Description
The intention of this function is not clear. Take a look.
``` JavaScript
const shouldShowForCurrentView = useCallback(() => {
if (!currentView) return true;
// Show for all views
return true;
}, [currentView]);
```
Did you mean false in the `if` statement?
### Steps to Reproduce
Take a look at the function and tell if there is any logic in it. What was the original intent?
### Expected Behavior
Should return different values or this is not needed at all.
### Browser and Version
Edge latest
### AppFlowy Version(s)
0.15
### Screenshots
_No response_
### Logs and Console Output
_No response_
### Additional Context
_No response_
贡献指南
这个仓库没有索引到贡献指南
评估
这个 Issue 还没有评估数据。