data query result and array length

I have queried a database for a form with result of 0 to insure only one use of form for user (their user email is the query item. I then have created another page, with a different form and query the same item to ensure that they can only complete this second form only once. However, this seems to conflict as the second form somehow can not separate that two different inputs can be allowed, no matter how I adjust the number in the results.

Here is the code for the array. And below the full code (the second page form is set exactly the same but for a different form on a different page. Any thoughts on correcting?

 .then( (results) => { 

// if an item for the user is not found
if (results.items === 0) { // even if I change to 1 or more on new form/page it blocks user
// create an item
const toInsert = {
“_id”: userId,
“email”: userEmail
};

AND THE FULL CODE:

import wixUsers from ‘wix-users’;
import wixData from ‘wix-data’;
import wixLocation from ‘wix-location’;

$w.onReady( () => {
if (wixUsers.currentUser.loggedIn) {
$w(“#button4”).label = “Logout”;
$w(“#button5”).show();
}
else {
$w(“#button4”).label = “Login”;
$w(“#button5”).hide();
}
} );

export function button4_onclick() {
// user is logged in
if (wixUsers.currentUser.loggedIn) {
// log the user out
wixUsers.logout()
.then( () => {
// update buttons accordingly
$w(“#button4”).label = “Login”;
$w(“#button5”).hide();
} );
}
// user is logged out
else {
let userId;
let userEmail;

// prompt the user to log in
wixUsers.promptLogin( {“mode”: “login”} )
.then( (user) => {
userId = user.id;
return user.getEmail();
} )
.then( (email) => {
// check if there is an item for the user in the collection
userEmail = email;
return wixData.query(“Profile”)
.eq(“_id”, userId)
.find();
} )
.then( (results) => {
// if an item for the user is not found
if (results.items.length === 0) {
// create an item
const toInsert = {
“_id”: userId,
“email”: userEmail
};
// add the item to the collection
wixData.insert(“Profile”, toInsert)
. catch ( (err) => {
console.log(err);
} );
}
// update buttons accordingly
$w(“#button4”).label = “Logout”;
$w(“#button5”).show();
} )
. catch ( (err) => {
console.log(err);
} );
}
}

export function button5_onclick() {
wixLocation.to(/Profile/Create/${wixUsers.currentUser.id});
}