Skip to content

Commit 8f13212

Browse files
committed
fix
1 parent d7aa17c commit 8f13212

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

components/Settings/QueryUrl.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ export const QueryUrl: FC<Props> = ({api, onApiChange}) => {
1616
const [newKey, setNewKey] = useState(api);
1717
const inputRef = useRef<HTMLInputElement>(null);
1818

19+
useEffect(() => {
20+
setNewKey(api);
21+
}, [api]);
22+
1923
const handleEnterDown = (e: KeyboardEvent<HTMLDivElement>) => {
2024
if (e.key === 'Enter') {
2125
e.preventDefault();

0 commit comments

Comments
 (0)