这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@imjaglan
Copy link
Contributor

@imjaglan imjaglan commented Jan 5, 2024

issue - #520

Now the invited user is not seeing the option to create a workspace of their own.

@review-agent-prime
Copy link

frontend/src/components/DefaultChat/index.jsx

The MESSAGES array is being created every time the component re-renders. This can be avoided by using the useMemo hook to only recompute the MESSAGES array when necessary.
Create Issue
See the diff
Checkout the fix

    const MESSAGES = useMemo(() => [
      // ...existing array elements
    ], []);
git fetch origin && git checkout -b ReviewBot/Impro-kcdumt3 origin/ReviewBot/Impro-kcdumt3

The MESSAGES array is quite large and makes the component difficult to read. Consider moving this array to a separate component or file and importing it into this component.
Create Issue
See the diff
Checkout the fix

    import MESSAGES from './Messages';
git fetch origin && git checkout -b ReviewBot/Impro-3c0lne3 origin/ReviewBot/Impro-3c0lne3

@timothycarambat timothycarambat self-assigned this Jan 5, 2024
@imjaglan
Copy link
Contributor Author

imjaglan commented Jan 6, 2024

hey @timothycarambat is there something wrong with the code?

@timothycarambat timothycarambat merged commit 5172bce into Mintplex-Labs:master Jan 8, 2024
@timothycarambat
Copy link
Member

@imjaglan Thanks for the contribution! If you would like a contributor badge in the Discord please ping me 🚀

cabwds pushed a commit to cabwds/anything-llm that referenced this pull request Jul 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants