I'm running two different scripts in my Google Sheet. One of them copies the formatting of the most recent cell into a new cell (I named it Format.gs). The second one sends an email about a new entry (named it Code.gs).

Independently, they run well, but as soon as I add them both into one Google Sheet, the one sending notifications stops working. I'm new to scripts, so any help is much appreciatd.

Here's the code of each script.

Format.gs

```
/**
 * @OnlyCurrentDoc
 */

const createTrigger = () => {
  ScriptApp.getProjectTriggers().forEach((trigger) => {
    ScriptApp.deleteTrigger(trigger);
  });
  ScriptApp.newTrigger('formRowOnFormSubmit').forSpreadsheet(SpreadsheetApp.getActive()).onFormSubmit().create();
};

const formRowOnFormSubmit = (e) => {
  if (!e) {
    throw new Error('Please do not run this function manually!');
  }
  const { range } = e;
  const row = range.getRowIndex();
  if (row > 2) {
    const sheet = range.getSheet();
    // Select the previous row range
    const sourceRange = sheet.getRange(`${row - 1}:${row - 1}`);
    // Get the recently added row
    const targetRange = sheet.getRange(`${row}:${row}`);
    // Copy the format only from the previous row to the current row
    sourceRange.copyTo(targetRange, SpreadsheetApp.CopyPasteType.PASTE_FORMAT, false);
  }
};

```

Code.gs

```
function processEdit(e) {  
  MailApp.sendEmail({
    to: "mail@gmail.com",
    subject: "New entry!",
    body: "Yay! New entry in the Google Sheet."

 });
} 

```