Skip to content

Commit 786a1a4

Browse files
committed
fix: session rename issues
1 parent 88af79f commit 786a1a4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/ChatConfigWindow.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ export default function ChatConfigWindow(props: Props) {
3131
if (dataEdit.name === '') {
3232
dataEdit.name = props.session.name
3333
}
34+
dataEdit.name = dataEdit.name.trim()
3435
props.save(dataEdit)
3536
props.close()
3637
}
@@ -49,7 +50,7 @@ export default function ChatConfigWindow(props: Props) {
4950
fullWidth
5051
variant="outlined"
5152
value={dataEdit.name}
52-
onChange={(e) => setDataEdit({ ...dataEdit, name: e.target.value.trim() })}
53+
onChange={(e) => setDataEdit({ ...dataEdit, name: e.target.value })}
5354
/>
5455
</DialogContent>
5556
<DialogActions>

0 commit comments

Comments
 (0)