Ok so I reset the module, and put the removed code back, hooked it to the 2 positions available and got it to eventually run.
Tried updating the test site and after copying the files and upgrading the database I get the following error.
CRITICAL - ErrorHandler - /home/********/public_html/var/cache/prod/FrontContainer.php line 2216 - Symfony\Component\DependencyInjection\Exception\InvalidArgumentException: The parameter "prestashop.installed_modules" must be defined.
then loading the B.O I get
An exception has been thrown during the rendering of a template ("An exception occurred while executing a query: SQLSTATE[42S22]: Column not found: 1054 Unknown column 't0.type' in 'SELECT'").
and the F.O shows this
[PrestaShopException]
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'theme_name' in 'WHERE'
at line 151 in file classes/db/DbPDO.php
146. protected function _query($sql)
147. {
148. try {
149. return $this->link->query($sql);
150. } catch (PDOException $exception) {
151. throw new PrestaShopException($exception->getMessage(), (int) $exception->getCode(), $exception);
152. }
153. }
154.
155. /**
156. * Returns the next row from the result set.
I tried the update twice.
I had the "Disable overrides" checked and tried with and withouth "disable non native modules" checked.