AppFlowy-IO / AppFlowy-IO/AppFlowy-Web

[Bug] Refactor this function to not always return the same value.

オープン
#406 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
TypeScript
スター
326
フォーク
167
平均マージ
17時間 6分
マージ済み PR(30日)
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 はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。