File tree 3 files changed +5
-12
lines changed
3 files changed +5
-12
lines changed Original file line number Diff line number Diff line change @@ -15,5 +15,4 @@ BUTTONDOWN_API_KEY=
15
15
16
16
CONVERTKIT_API_URL = https://api.convertkit.com/v3/
17
17
CONVERTKIT_API_KEY =
18
- CONVERTKIT_TIPS_FORM_ID =
19
- CONVERTKIT_MONTHLY_FORM_ID =
18
+ CONVERTKIT_FORM_ID =
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ const siteMetadata = {
25
25
newsletter : {
26
26
// supports mailchimp, buttondown, convertkit
27
27
// Please add your .env file and modify it according to your selection
28
- provider : 'mailchimp ' ,
28
+ provider : 'convertkit ' ,
29
29
} ,
30
30
comment : {
31
31
// Select a provider and use the environment variables associated to it
Original file line number Diff line number Diff line change 1
1
/* eslint-disable import/no-anonymous-default-export */
2
2
export default async ( req , res ) => {
3
- const { email, list } = req . query
3
+ const { email } = req . body
4
+ console . log ( 'email : ' , email )
4
5
5
6
if ( ! email ) {
6
7
return res . status ( 400 ) . json ( { error : 'Email is required' } )
7
8
}
8
9
9
- if ( ! list ) {
10
- return res . status ( 400 ) . json ( { error : 'List is required' } )
11
- }
12
-
13
10
try {
14
- const FORM_ID =
15
- list === '12-tips-production-apps'
16
- ? process . env . CONVERTKIT_TIPS_FORM_ID
17
- : process . env . CONVERTKIT_MONTHLY_FORM_ID
11
+ const FORM_ID = process . env . CONVERTKIT_FORM_ID
18
12
const API_KEY = process . env . CONVERTKIT_API_KEY
19
13
const API_URL = process . env . CONVERTKIT_API_URL
20
14
You can’t perform that action at this time.
0 commit comments