WIP CORS issues and need to add modularization and func ref checking