Using varaibles in rest query to sharepoint

Hi,

I am trying to get the name and lastname from a people column so I can check if the current logged in user is the same as the one in the people column.

To get the current logged in user I am using this code:

let currentUser = '';
  sp.web.currentUser.get().then(result => {
    currentUser = result.Title;
  });

and to get the name and lastname from the people column I am using this:

private select = "SalesManager/FirstName, SalesManager/LastName";

const managerName = await sp.web.lists
    .getByTitle(this.listTitle)
    .items.select(this.select)
    .expand("SalesManager")
    .get();

What I want to do now is fetch the salesManager name and lastname that match the currentUser name and lastname.
I tried this:

managerName.forEach(item => {
      salesManagerName.push (item.SalesManager.FirstName + " " + item.SalesManager.LastName);
    });

    let agreementOwner = '';
    salesManagerName.forEach(item => {
      if(item == currentUser) {
        agreementOwner = item;
      }
    });

    
  const items = await sp.web.lists
    .getByTitle(this.listTitle)
    .items.select(this.select)
    .filter(`'${agreementOwner}' eq '${currentUser}'`)
    .expand("SalesManager")
    .get();

But is not working and the console is not helping to find the proble, it only says: “The query is no valid”
So I am wondering if it is possible to use varaibles like “agreementOwner” in the filter.

Is it possible?