Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Can not edit mail templates when no theme is selected #58

@patrickjahns

Description

@patrickjahns

Steps to reproduce

Install templateeditor from https://github.com/owncloud/templateeditor/tree/release/0.2.0
Do not have a custom template enabled
Edit one of the templates and try to save

Expected Behavior

I can edit/save the (default) template

Actual Behavior

... empty text field in which I can write text - but saving is stuck
image

OC exception:

{
"reqId":"cpjG1XrmvLlxJ58JnJYR",
"level":3,
"time":"2017-12-04T10:52:32+00:00",
"remoteAddr":"172.17.0.1",
"user":"admin"
,"app":"index",
"method":"POST",
"url":"/owncloud/index.php/apps/templateeditor/settings/mailtemplate",
"message":"Exception: {
"Exception":"TypeError","Message":"Argument 1 passed to OCA\TemplateEditor\MailTemplate::__construct() must implement interface OCP\Theme\ITheme, boolean given, called in /var/www/owncloud/apps/templateeditor/lib/TemplateEditor.php on line 90","Code":0,"Trace":"nn
#0 /var/www/owncloud/apps/templateeditor/lib/TemplateEditor.php(90): OCA\TemplateEditor\MailTemplate->__construct(false, 'core/templates/...')
n#1 /var/www/owncloud/apps/templateeditor/lib/Controller/AdminSettingsController.php(72): OCA\TemplateEditor\TemplateEditor->getMailTemplate('', 'core/templates/...')
n#2 [internal function]: OCA\TemplateEditor\Controller\AdminSettingsController->updateTemplate('', 'core/templates/...', 'asdfsaf')
n#3 /var/www/owncloud/lib/private/AppFramework/Http/Dispatcher.php(159): call_user_func_array(Array, Array)
n#4 /var/www/owncloud/lib/private/AppFramework/Http/Dispatcher.php(89): OC\AppFramework\Http\Dispatcher->executeController(Object(OCA\TemplateEditor\Controller\AdminSettingsController), 'updateTemplate')
n#5 /var/www/owncloud/lib/private/AppFramework/App.php(98): OC\AppFramework\Http\Dispatcher->dispatch(Object(OCA\TemplateEditor\Controller\AdminSettingsController), 'updateTemplate')
n#6 /var/www/owncloud/lib/private/AppFramework/Routing/RouteActionHandler.php(46): OC\AppFramework\App::main('OCA\TemplateEdi...', 'updateTemplate', Object(OC\AppFramework\DependencyInjection\DIContainer), Array)
n#7 [internal function]: OC\AppFramework\Routing\RouteActionHandler->__invoke(Array)
n#8 /var/www/owncloud/lib/private/Route/Router.php(307): call_user_func(Object(OC\AppFramework\Routing\RouteActionHandler), Array)
n#9 /var/www/owncloud/lib/base.php(928): OC\Route\Router->match('/apps/templatee...')
n#10 /var/www/owncloud/index.php(56): OC::handleRequest()
n#11 {main}","File":"/var/www/owncloud/apps/templateeditor/lib/MailTemplate.php","Line":38}"
}

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions