diff --git a/docs/docusaurus/docs/classes/alter-table.md b/docs/docusaurus/docs/classes/alter-table.md index b1aa3a4..7a54c0e 100644 --- a/docs/docusaurus/docs/classes/alter-table.md +++ b/docs/docusaurus/docs/classes/alter-table.md @@ -47,7 +47,7 @@ The new desired structure for the table to get. *** ### execute() -`async` → () → __any__ +`async` → () → [Instance.checkStructure()](./instance#checkstructure) :::warning Possible crash [structure()](#structure) must always be given. diff --git a/docs/docusaurus/docs/classes/create-table.md b/docs/docusaurus/docs/classes/create-table.md index 6fa36ca..4d3d439 100644 --- a/docs/docusaurus/docs/classes/create-table.md +++ b/docs/docusaurus/docs/classes/create-table.md @@ -60,7 +60,7 @@ The desired structure for the table to get. *** ### execute() -`async` → () → __any__ +`async` → () → [OkPacket](../typedefs/okpacket) :::warning Possible crash [structure()](#structure) must always be given. @@ -70,6 +70,6 @@ Executes the prepared query. **Returns** -→ __any__ - The result of 'CREATE TABLE [...]'-query +→ [OkPacket](../typedefs/okpacket) *** \ No newline at end of file diff --git a/docs/docusaurus/docs/classes/delete.md b/docs/docusaurus/docs/classes/delete.md index 638546c..8ed89b5 100644 --- a/docs/docusaurus/docs/classes/delete.md +++ b/docs/docusaurus/docs/classes/delete.md @@ -64,12 +64,12 @@ Enables deletion of all rows. *** ### execute() -`async` → () → __any__ +`async` → () → [OkPacket](../typedefs/okpacket) Executes the prepared query. **Returns** -→ __any__ - Query result +→ [OkPacket](../typedefs/okpacket) *** \ No newline at end of file diff --git a/docs/docusaurus/docs/classes/insert.md b/docs/docusaurus/docs/classes/insert.md index f2d58f6..9910e94 100644 --- a/docs/docusaurus/docs/classes/insert.md +++ b/docs/docusaurus/docs/classes/insert.md @@ -43,12 +43,12 @@ The data (rows) to insert. *** ### execute() -`async` → () → __any__ +`async` → () → [OkPacket](../typedefs/okpacket) Executes the prepared query. **Returns** -→ __any__ - Query result +→ [OkPacket](../typedefs/okpacket) *** \ No newline at end of file diff --git a/docs/docusaurus/docs/classes/select.md b/docs/docusaurus/docs/classes/select.md index ace8a31..bca19de 100644 --- a/docs/docusaurus/docs/classes/select.md +++ b/docs/docusaurus/docs/classes/select.md @@ -293,12 +293,13 @@ Paginates the query. *** ### execute() -`async` → () → __any__ +`async` → () → __Number__ / __Array__\<__Object__\> Executes the prepared query. **Returns** -→ __any__ - Query result +→ __Number__ - Numerical results
+→ __Array__\<__Object__\> - Row data *** \ No newline at end of file diff --git a/docs/docusaurus/docs/classes/update.md b/docs/docusaurus/docs/classes/update.md index 844831d..1890a4c 100644 --- a/docs/docusaurus/docs/classes/update.md +++ b/docs/docusaurus/docs/classes/update.md @@ -81,12 +81,12 @@ Adds a where-clause to the query *** ### execute() -`async` → () → __any__ +`async` → () → [OkPacket](../typedefs/okpacket) Executes the prepared query. **Returns** -→ __any__ - Query result +→ [OkPacket](../typedefs/okpacket) *** \ No newline at end of file diff --git a/lib/Delete.js b/lib/Delete.js index 19dba9d..126bc5d 100644 --- a/lib/Delete.js +++ b/lib/Delete.js @@ -57,7 +57,7 @@ class Delete { /** * Executes the prepared querry - * @returns {Any} + * @returns {import("../index").OkPacket} */ async execute(){ if (!this.#instance.isConnected()) throw new Error(`Can't execute query: Instance has no connection`); diff --git a/lib/Insert.js b/lib/Insert.js index 0d62f39..fac3d68 100644 --- a/lib/Insert.js +++ b/lib/Insert.js @@ -42,7 +42,7 @@ class Insert { /** * Executes the prepared querry - * @returns {Any} + * @returns {import("../index").OkPacket} */ async execute(){ if (!this.#data) throw new Error("Insert: tried to insert without data"); diff --git a/lib/Tables.js b/lib/Tables.js index 536c523..108a1ae 100644 --- a/lib/Tables.js +++ b/lib/Tables.js @@ -44,7 +44,7 @@ class AlterTable { /** * Executes the prepared querry - * @returns {Any} + * @returns {import("../index").CheckResult} */ async execute(){ if (!this.#database) throw new Error(`Can't alter table ${this.#name}: Database not selected`); @@ -170,7 +170,7 @@ class CreateTable { /** * Executes the prepared querry - * @returns {Any} + * @returns {import("../index").OkPacket} */ async execute(){ if (!this.#database) throw new Error(`Can't create table ${this.#name}: Database not selected`); diff --git a/lib/Update.js b/lib/Update.js index b868a34..d9e7fbd 100644 --- a/lib/Update.js +++ b/lib/Update.js @@ -69,7 +69,7 @@ class Update{ /** * Executes the prepared querry - * @returns {Any} + * @returns {import("../index").OkPacket} */ async execute(){ if (!this.#instance.isConnected()) throw new Error(`Can't execute query: Instance has no connection`);