Unable to complete the challenge

Tell us what’s happening:
Describe your issue in detail here.

Used the built-in SECRETS tab to add the variable in Replit.

// Serve JSON on a Specific Route
app.get("/json", (req, res) => {
// Use the .env File
const mySecret = process.env[“MESSAGE_STYLE”]
res.json({“message”: mySecret == “uppercase” ? “HELLO JSON” : “Hello Json”});

Your project link(s)

solution: https://replit.com/@rwild1/boilerplate-express

Challenge: Use the .env File

Link to the challenge:

in challenge it has value “Hello json”, in your code it’s “Hello Json”
capital J screw things up


This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.