diff --git a/services/gunDB/contact-api/actions.js b/services/gunDB/contact-api/actions.js index 25b98004..a0ae6171 100644 --- a/services/gunDB/contact-api/actions.js +++ b/services/gunDB/contact-api/actions.js @@ -1269,7 +1269,15 @@ const createPost = async (tags, title, content) => { v => typeof v !== 'number' ) - return typeof maybeNumOfPages === 'number' ? maybeNumOfPages : 0 + if (typeof maybeNumOfPages !== 'number') { + throw new TypeError( + `Could not fetch number of pages from wall, instead got: ${JSON.stringify( + maybeNumOfPages + )}` + ) + } + + return maybeNumOfPages })() let pageIdx = Math.max(0, numOfPages - 1).toString()