π¨ The ultimate agentic social media scheduling tool π€
TypeScript nextjsopen-sourceopen-source-social-media-scheduling-toolosspostiz-cloudpostiz-hostedredisscheduling-toolsocial-media-scheduling-tooltypescript
feat: throw wordpress
Nevo David95956fe345ff
diff --git a/libraries/nestjs-libraries/src/integrations/social/wordpress.provider.ts b/libraries/nestjs-libraries/src/integrations/social/wordpress.provider.tsindex a1094e3af..cda50772a 100644--- a/libraries/nestjs-libraries/src/integrations/social/wordpress.provider.ts+++ b/libraries/nestjs-libraries/src/integrations/social/wordpress.provider.ts@@ -101,7 +101,7 @@ export class WordpressProviderconst auth = Buffer.from(`${body.username}:${body.password}`).toString('base64');- const { id, name, avatar_urls } = await (+ const { id, name, avatar_urls, code } = await (await fetch(`${body.domain}/wp-json/wp/v2/users/me`, {headers: {Authorization: `Basic ${auth}`,@@ -109,6 +109,10 @@ export class WordpressProvider})).json();+ if (code) {+ throw "Invalid credentials";+ }+const biggestImage = Object.entries(avatar_urls || {}).reduce((all, current) => {if (all > Number(current[0])) {