Skip to content

Commit

Permalink
Merge pull request #48 from Butterstroke/development
Browse files Browse the repository at this point in the history
Release 1.11.2
  • Loading branch information
AurelicButter authored Mar 16, 2022
2 parents bc9c7c1 + 2588f00 commit 7dd7b45
Show file tree
Hide file tree
Showing 42 changed files with 155 additions and 142 deletions.
12 changes: 6 additions & 6 deletions docs/AniList.Activity.html
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ <h2>
<h3 class="subsection-title">Methods</h3>

<h4 class="name" id="delete">
<span class="type-signature"></span>delete<span class="signature">(id)</span
<span class="type-signature">(async) </span>delete<span class="signature">(id)</span
><span class="type-signature"> &rarr; {Boolean}</span>
</h4>

Expand All @@ -210,7 +210,7 @@ <h4 class="name" id="delete">
<ul class="dummy">
<li>
<a href="activity.js.html">activity.js</a>,
<a href="activity.js.html#line145">line 145</a>
<a href="activity.js.html#line144">line 144</a>
</li>
</ul>
</dd>
Expand Down Expand Up @@ -449,7 +449,7 @@ <h5>Returns:</h5>
</dl>

<h4 class="name" id="postMessage">
<span class="type-signature"></span>postMessage<span class="signature"
<span class="type-signature">(async) </span>postMessage<span class="signature"
>(text, recipientId, isPrivate, id<span class="signature-attributes">nullable</span>)</span
><span class="type-signature">
&rarr; {<a href="global.html#MessageActivity">MessageActivity</a>}</span
Expand All @@ -462,7 +462,7 @@ <h4 class="name" id="postMessage">
<ul class="dummy">
<li>
<a href="activity.js.html">activity.js</a>,
<a href="activity.js.html#line116">line 116</a>
<a href="activity.js.html#line115">line 115</a>
</li>
</ul>
</dd>
Expand Down Expand Up @@ -567,7 +567,7 @@ <h5>Returns:</h5>
</dl>

<h4 class="name" id="postText">
<span class="type-signature"></span>postText<span class="signature"
<span class="type-signature">(async) </span>postText<span class="signature"
>(text, id<span class="signature-attributes">nullable</span>)</span
><span class="type-signature">
&rarr; {<a href="global.html#TextActivity">TextActivity</a>}</span
Expand Down Expand Up @@ -656,7 +656,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.Lists.html
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.Media.html
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.People.html
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.Recommendation.html
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.Search.html
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.Thread.html
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
16 changes: 8 additions & 8 deletions docs/AniList.User.html
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ <h4 class="name" id="all">
<dt class="tag-source">Source:</dt>
<dd class="tag-source">
<ul class="dummy">
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line48">line 48</a></li>
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line55">line 55</a></li>
</ul>
</dd>

Expand Down Expand Up @@ -276,7 +276,7 @@ <h4 class="name" id="getAuthorized">
<dt class="tag-source">Source:</dt>
<dd class="tag-source">
<ul class="dummy">
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line85">line 85</a></li>
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line91">line 91</a></li>
</ul>
</dd>

Expand Down Expand Up @@ -308,7 +308,7 @@ <h4 class="name" id="getRecentActivity">
<dt class="tag-source">Source:</dt>
<dd class="tag-source">
<ul class="dummy">
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line61">line 61</a></li>
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line68">line 68</a></li>
</ul>
</dd>

Expand Down Expand Up @@ -374,7 +374,7 @@ <h4 class="name" id="profile">
<dt class="tag-source">Source:</dt>
<dd class="tag-source">
<ul class="dummy">
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line25">line 25</a></li>
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line32">line 32</a></li>
</ul>
</dd>

Expand Down Expand Up @@ -437,7 +437,7 @@ <h4 class="name" id="stats">
<dt class="tag-source">Source:</dt>
<dd class="tag-source">
<ul class="dummy">
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line37">line 37</a></li>
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line44">line 44</a></li>
</ul>
</dd>

Expand Down Expand Up @@ -492,15 +492,15 @@ <h5>Returns:</h5>
</dl>

<h4 class="name" id="update">
<span class="type-signature"></span>update<span class="signature">(options)</span
<span class="type-signature">(async) </span>update<span class="signature">(options)</span
><span class="type-signature"> &rarr; {<a href="global.html#UserOptions">UserOptions</a>}</span>
</h4>

<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source">
<ul class="dummy">
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line100">line 100</a></li>
<li><a href="user.js.html">user.js</a>, <a href="user.js.html#line106">line 106</a></li>
</ul>
</dd>

Expand Down Expand Up @@ -557,7 +557,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/AniList.html
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,7 @@ <h5>Returns:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
21 changes: 10 additions & 11 deletions docs/activity.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -275,22 +275,21 @@ <h1 class="page-title">activity.js</h1>
* @returns {TextActivity}
* @since 1.11.0
*/
postText(text, id) {
async postText(text, id) {
if (typeof text !== "string") {
throw new Error("Text is not a string type.");
}
if (id &amp;&amp; typeof id !== "number") {
throw new Error("Provided ID is not a number type.");
}

const data = this.util.send(
const data = await this.util.send(
`mutation ($id: Int, $text: String) {
SaveTextActivity(id: $id, text: $text) {
${TextActivityQuery}
} }`,
SaveTextActivity(id: $id, text: $text) {
${TextActivityQuery}
} }`,
{ id: id, text: text }
);

return data.SaveTextActivity;
}

Expand All @@ -304,7 +303,7 @@ <h1 class="page-title">activity.js</h1>
* @returns {MessageActivity}
* @since 1.11.0
*/
postMessage(text, recipientId, isPrivate = false, id) {
async postMessage(text, recipientId, isPrivate = false, id) {
if (typeof text !== "string") {
throw new Error("Text is not a string type.");
}
Expand All @@ -315,7 +314,7 @@ <h1 class="page-title">activity.js</h1>
throw new Error("Provided ID is not a number type.");
}

const data = this.util.send(
const data = await this.util.send(
`mutation ($id: Int, $text: String, $recipientId: Int, $private: Boolean) {
SaveMessageActivity(message: $text, id: $id, recipientId: $recipientId, private: $private) {
${MessageActivityQuery}
Expand All @@ -333,12 +332,12 @@ <h1 class="page-title">activity.js</h1>
* @returns {Boolean} Returns true if successful
* @since 1.11.0
*/
delete(id) {
async delete(id) {
if (typeof id !== "number") {
throw new Error("ID is not a number type.");
}

const data = this.util.send(`mutation ($id: Int) { DeleteActivity(id: $id) { deleted } }`, { id: id });
const data = await this.util.send(`mutation ($id: Int) { DeleteActivity(id: $id) { deleted } }`, { id: id });

return data.DeleteActivity.deleted;
}
Expand All @@ -353,7 +352,7 @@ <h1 class="page-title">activity.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
6 changes: 3 additions & 3 deletions docs/docDefinition.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -695,7 +695,7 @@ <h1 class="page-title">docDefinition.js</h1>
* @property { String } replies.text - The content of the reply
* @property { Number } replies.likeCount - The amount of likes on the reply
* @property { Boolean } isLocked - True if the activity cannot receive replies
* @property { Boolean } isSubscribed - [Requires Login] True if the authorized user is subscribed.
* @property { Boolean } isSubscribed - [Requires Login] True if the authorized user is subscribed.
* @property { Boolean } isLiked - [Requires Login] True if authorized user liked it
* @property { UserRelation[] } likes - All users who liked the activity
*/
Expand All @@ -713,7 +713,7 @@ <h1 class="page-title">docDefinition.js</h1>
* @property { String } replies.text - The content of the reply
* @property { Number } replies.likeCount - The amount of likes on the reply
* @property { Boolean } isLocked - True if the activity cannot receive replies
* @property { Boolean } isSubscribed - [Requires Login] True if the authorized user is subscribed.
* @property { Boolean } isSubscribed - [Requires Login] True if the authorized user is subscribed.
* @property { Boolean } isLiked - [Requires Login] True if authorized user liked it
* @property { UserRelation[] } likes - All users who liked the activity
*/
Expand Down Expand Up @@ -981,7 +981,7 @@ <h1 class="page-title">docDefinition.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
8 changes: 6 additions & 2 deletions docs/fetcher.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,10 @@ <h1 class="page-title">fetcher.js</h1>
throw new Error("Query or variables are not given!");
}

if (query.startsWith("mutation") &amp;&amp; this.key === null) {
throw new Error("Function requires authenciation but no authorization found.");
}

const controller = new AbortController();
const requestTimeout = setTimeout(() => {
controller.abort();
Expand All @@ -326,7 +330,7 @@ <h1 class="page-title">fetcher.js</h1>

const response = await fetch("https://graphql.anilist.co", options)
.catch((error) => {
if (error instanceof fetch.AbortError) {
if (error.name === "AbortError") {
throw new Error(`ERROR: Request timed out after ${this.options.timeout}ms, is AniList up?`);
}
})
Expand Down Expand Up @@ -438,7 +442,7 @@ <h1 class="page-title">fetcher.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/global.html
Original file line number Diff line number Diff line change
Expand Up @@ -10920,7 +10920,7 @@ <h5>Type:</h5>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ <h2>License and Contact</h2>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/index.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ <h1 class="page-title">index.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/lists.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ <h1 class="page-title">lists.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/media.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ <h1 class="page-title">media.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/people.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ <h1 class="page-title">people.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/recommendation.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ <h1 class="page-title">recommendation.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/search.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ <h1 class="page-title">search.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
2 changes: 1 addition & 1 deletion docs/thread.js.html
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ <h1 class="page-title">thread.js</h1>
<br class="clear" />

<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.7</a> using the
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a> using the
<a href="https://github.com/clenemt/docdash">docdash</a> theme.
</footer>

Expand Down
Loading

0 comments on commit 7dd7b45

Please sign in to comment.