
I have a function that takes inputs and depending on those inputs executes different methods. No matter what I set path1 to, it always returns the same value, which is whatever the value of path1 was when the server function was first executed.
For example, in the attachment - res.send(path1) always returns 63ac838005209fd1b692", even if i change path1 in the createExecution command.
This is resulting in the incorrect method being fired, as each method refers to a different database.
I have tried redeploying the function so am quite stumped as to what is happening.

You should be using req.variables
rather than process.env
. see https://appwrite.io/docs/functions#writingYourOwnFunction
Recommended threads
- custom requirements.txt file
How do I specify a custom requirements.txt file when creating a serverless function through the Appwrite console?
- Is my approach for deleting registered u...
A few weeks ago, I was advised not to use the registered users' id in my web app. Instead, I store the publicly viewable information such as username and email ...
- ❗[Help] Function stuck in "waiting" stat...
Hi Appwrite team 👋 I'm trying to contribute to Appwrite and followed the official setup instructions from the CONTRIBUTING.md guide to run the platform locall...
