summaryrefslogtreecommitdiff
path: root/program/steps/utils
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-05-03 12:33:02 +0200
committerAleksander Machniak <alec@alec.pl>2013-05-03 12:33:02 +0200
commitcfe2fc8b30e7e5c21452239a36301fdaeffdfd7d (patch)
tree9e9bda8d00d20b599dbbaef3bba6192115ac01d6 /program/steps/utils
parent107cbd1a0ebbf5eef195b19353a4ccd7f4aecc0e (diff)
Log spellchecker error also in html mode
Diffstat (limited to 'program/steps/utils')
-rw-r--r--program/steps/utils/spell.inc2
-rw-r--r--program/steps/utils/spell_html.inc5
2 files changed, 6 insertions, 1 deletions
diff --git a/program/steps/utils/spell.inc b/program/steps/utils/spell.inc
index b59fe7998..38e4ca285 100644
--- a/program/steps/utils/spell.inc
+++ b/program/steps/utils/spell.inc
@@ -43,7 +43,7 @@ else {
}
if ($err = $spellchecker->error()) {
- raise_error(array('code' => 500, 'type' => 'php',
+ rcube::raise_error(array('code' => 500, 'type' => 'php',
'file' => __FILE__, 'line' => __LINE__,
'message' => sprintf("Spell check engine error: " . $err)),
true, false);
diff --git a/program/steps/utils/spell_html.inc b/program/steps/utils/spell_html.inc
index 861e4ba48..96b41e230 100644
--- a/program/steps/utils/spell_html.inc
+++ b/program/steps/utils/spell_html.inc
@@ -46,6 +46,11 @@ else if ($request['method'] == 'learnWord') {
}
if ($error = $spellchecker->error()) {
+ rcube::raise_error(array('code' => 500, 'type' => 'php',
+ 'file' => __FILE__, 'line' => __LINE__,
+ 'message' => sprintf("Spell check engine error: " . $error)),
+ true, false);
+
echo '{"error":{"errstr":"' . addslashes($error) . '","errfile":"","errline":null,"errcontext":"","level":"FATAL"}}';
exit;
}