function with .then() gets Ignored

Hello everyone, I’m new to Wix and I’m currently trying to gather the information about the shopping cart and further process the information.
Here is a code snippet:

export async function somefunctionname {
//some code
getCurrentCart().then( ( result )=> {

  const options = {
   variables:{
     name: JSON.stringify(result)
     }
 }
//further processing
});
}

Whenever I try to run the code, it just gets skipped/ignored.
It would be great if someone could point me in the right direction.

Its not clear how that function is being used, and what it returns. Also are you using the right wix-stores getCurrentCart() or is it your own function?