Skip to content

Commit

Permalink
[Bugfix] The "send" button for chat should be enabled for logged in u…
Browse files Browse the repository at this point in the history
…sers (#2202)

* Update QuestionInput.tsx

* Add additional boolean for disabling sendquest

---------

Co-authored-by: Pamela Fox <[email protected]>
  • Loading branch information
jeannotdamoiseaux and pamelafox authored Dec 2, 2024
1 parent 829a7a6 commit f00d36d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export const QuestionInput = ({ onSend, disabled, placeholder, clearOnSend, init
};

const disableRequiredAccessControl = requireLogin && !loggedIn;
const sendQuestionDisabled = disabled || !question.trim() || requireLogin;
const sendQuestionDisabled = disabled || !question.trim() || disableRequiredAccessControl;

if (disableRequiredAccessControl) {
placeholder = "Please login to continue...";
Expand Down

0 comments on commit f00d36d

Please sign in to comment.