mirror of
https://github.com/drawdb-io/drawdb.git
synced 2025-10-21 10:43:58 +00:00
Fix import
This commit is contained in:
@@ -1245,10 +1245,10 @@ export default function ControlPanel({
|
||||
return;
|
||||
}
|
||||
const reader = new FileReader();
|
||||
reader.onload = function (event) {
|
||||
reader.onload = async (e) => {
|
||||
let jsonObject = null;
|
||||
try {
|
||||
jsonObject = JSON.parse(event.target.result);
|
||||
jsonObject = JSON.parse(e.target.result);
|
||||
} catch (error) {
|
||||
setError({
|
||||
type: STATUS.ERROR,
|
||||
|
@@ -19,7 +19,7 @@ const tableSchema = {
|
||||
notNull: { type: "boolean" },
|
||||
increment: { type: "boolean" },
|
||||
comment: { type: "string" },
|
||||
length: { type: ["string", "number"] },
|
||||
size: { type: ["string", "number"] },
|
||||
values: { type: "array", items: { type: "string" } },
|
||||
},
|
||||
required: [
|
||||
|
Reference in New Issue
Block a user