mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-10-17 08:38:24 +00:00
fix: do not reuse state variable directly
This commit is contained in:
@@ -107,7 +107,7 @@ const LogsTable = () => {
|
||||
if (startIdx === 0) {
|
||||
setLogs(data);
|
||||
} else {
|
||||
let newLogs = logs;
|
||||
let newLogs = [...logs];
|
||||
newLogs.push(...data);
|
||||
setLogs(newLogs);
|
||||
}
|
||||
|
Reference in New Issue
Block a user