I am encountering a peculiar issue with two arrays of objects in my program. One array is named "Responses" and the other is called "Questions." The problem arises when I remove the first element from an object in the "Questions" array using shift() method. Surprisingly, the second array "Responses" also gets affected even though I haven't explicitly called shift() on it. Below is the snippet of code causing this behavior:
private async Sousstep(stepContext: WaterfallStepContext): Promise<DialogTurnResult> {
const siteDetails = stepContext.options as SiteDetails;
// Logic goes here...
}