File tree Expand file tree Collapse file tree 3 files changed +5
-4
lines changed
libraries/nestjs-libraries/src/integrations/social Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -72,6 +72,7 @@ DISCORD_BOT_TOKEN_ID=""
7272SLACK_ID = " "
7373SLACK_SECRET = " "
7474SLACK_SIGNING_SECRET = " "
75+ MASTODON_URL = " https://mastodon.social"
7576MASTODON_CLIENT_ID = " "
7677MASTODON_CLIENT_SECRET = " "
7778
Original file line number Diff line number Diff line change @@ -74,7 +74,7 @@ export class MastodonCustomProvider extends MastodonProvider {
7474 return this . dynamicPost (
7575 id ,
7676 accessToken ,
77- 'https://mastodon.social' ,
77+ process . env . MASTODON_URL || 'https://mastodon.social' ,
7878 postDetails
7979 ) ;
8080 }
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ export class MastodonProvider extends SocialAbstract implements SocialProvider {
3939 async generateAuthUrl ( ) {
4040 const state = makeId ( 6 ) ;
4141 const url = this . generateUrlDynamic (
42- 'https://mastodon.social' ,
42+ process . env . MASTODON_URL || 'https://mastodon.social' ,
4343 state ,
4444 process . env . MASTODON_CLIENT_ID ! ,
4545 process . env . FRONTEND_URL !
@@ -102,7 +102,7 @@ export class MastodonProvider extends SocialAbstract implements SocialProvider {
102102 return this . dynamicAuthenticate (
103103 process . env . MASTODON_CLIENT_ID ! ,
104104 process . env . MASTODON_CLIENT_SECRET ! ,
105- 'https://mastodon.social' ,
105+ process . env . MASTODON_URL || 'https://mastodon.social' ,
106106 params . code
107107 ) ;
108108 }
@@ -179,7 +179,7 @@ export class MastodonProvider extends SocialAbstract implements SocialProvider {
179179 return this . dynamicPost (
180180 id ,
181181 accessToken ,
182- 'https://mastodon.social' ,
182+ process . env . MASTODON_URL || 'https://mastodon.social' ,
183183 postDetails
184184 ) ;
185185 }
You can’t perform that action at this time.
0 commit comments