Why are the nested async/await is not waiting?

I have read a lot of docs and watch a bunch of video and I just can’t seem to get this to work. The workflow is this:

  1. get a http request
  2. request gets processed by an async function.
  3. this function needs to call two more async functions in seq order.

The issue is that the first async function gets called, but it doesn’t wait. My linter shows me the message ”await’ has no effect on the type of this expression.’ for both createvm and controlvm. I am using nodejs/express. I will just post the skeleton of the code. It has got to be something really simple, but I just can’t see it.

Entry point from route:

const add = async (req, res) => {
  // destructure the request body
  const { username, uid } = req.body;


  // create vm via proxmox api
  try {
    await createVM(username, pveName, uid);
    await controlVM("start", pveName, uid);
    return res.status(200).json({
      success: true,
    });
  } catch (e) {
    errorLog("vmCont", "add", e.message, req, "error");
    return res.status(500).json({
      success: false,
      error: e.message,
    });
  }
};

Here is the createvm function:

const createVM = async (username, pveName, uid) => {
  try {
    const myConfig = {
      url: `/api2/json/nodes/temppve/qemu/10000/clone`,
      method: "post",
      baseURL: `${process.env.PROXMOX_apiurl}`,
      headers: {
        Authorization: `PVEAPIToken=${process.env.PROXMOX_apikey}`,
        "Content-Type": "application/json",
      },
      data: {
        newid: uid,
        description: `Server for ${username}`,
        full: 1,
        name: username,
        storage: "local-lvm",
        target: pveName,
      },
      httpsAgent: new https.Agent({ rejectUnauthorized: false }),
    };

    await axios(myConfig);
    return;
  } catch (e) {
    errorLog("proxmox", "createVM", e.message, false, "error");
    throw new Error(e.message);
  }
};

The the controlvm needs to fire after the vm is created:

const controlVM = async (action, node, vmid) => {
  let myConfig = {
    method: "post",
    maxBodyLength: Infinity,
    baseURL: `${process.env.PROXMOX_apiurl}`,
    url: `/api2/json/nodes/${node}/qemu/${vmid}/status/${action}`,
    headers: {
      Authorization: `PVEAPIToken=${process.env.PROXMOX_apikey}`,
    },
    data: "",
    httpsAgent: new https.Agent({ rejectUnauthorized: false }),
  };

  try {
    await axios(myConfig);
    return;
  } catch (e) {
    errorLog("proxmox", "controlVM", e.message, false, "error");
    throw new Error(e.message);
  }
};