64
« Last post by mwindey on October 07, 2026, 01:06:14 PM »
Hi,
I noticed a PHP warning in Osclass 8.4 while editing/saving an email template in the backoffice.
The following warning was logged 4 times during the same action:
```text
PHP Warning: Undefined array key "i_order" in
/oc-includes/osclass/model/Page.php on line 357
```
Line 357 is inside `Page::deleteByPrimaryKey()`:
```php
public function deleteByPrimaryKey($id) {
$row = $this->findByPrimaryKey($id);
$order = $row['i_order'];
$this->reOrderPages($order);
$this->dao->delete($this->getDescriptionTableName(), array('fk_i_pages_id' => $id));
return $this->dao->delete($this->tableName, array('pk_i_id' => $id));
}
```
It looks like `findByPrimaryKey($id)` can return an empty array (or a row without `i_order`), while `deleteByPrimaryKey()` assumes that `i_order` is always present.
The warning appeared immediately after I edited/saved an email template in the backoffice. The template itself appears to have been saved correctly and I have not noticed any other problem.
So this does not seem critical, but it may be an edge case in the new 8.4 page/order handling or email-template cleanup.
Just reporting it in case it is useful. 🙂