Skip to content

Commit

Permalink
fix: update CORS configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
hackerman70000 committed Feb 1, 2025
1 parent 8236eb2 commit 9e2ebca
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion backend/app/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@

def create_app(config_class=Config):
app = Flask(__name__, static_url_path="/static", static_folder="static")
CORS(app, resources={r"/api/*": {"origins": "http://localhost"}})
CORS(
app,
resources={
r"/api/*": {"origins": ["http://localhost:3000", "http://localhost:8081"]}
},
)
app.config.from_object(config_class)

# Initialize database
Expand Down

0 comments on commit 9e2ebca

Please sign in to comment.