From: Joey Schulze Date: Mon, 24 Feb 2014 18:49:41 +0000 (+0100) Subject: Rico Bugfix: Prevent translation error X-Git-Url: https://git.infodrom.org/?p=infodrom%2Fhallinta;a=commitdiff_plain;h=e1b3006db5798bf70b4c2427b8f3de1363e718e5 Rico Bugfix: Prevent translation error --- diff --git a/lib/rico/ricoLiveGridForms.js b/lib/rico/ricoLiveGridForms.js index 2b12135..ace80ef 100644 --- a/lib/rico/ricoLiveGridForms.js +++ b/lib/rico/ricoLiveGridForms.js @@ -605,7 +605,7 @@ Rico.TableEdit = Class.create( processResponse: function() { var responseText,success=true; var respNodes=Element.select(this.responseDiv,'.ricoFormResponse'); - if (respNodes) { + if (respNodes && respNodes.length) { // generate a translated response var phraseId=$w(respNodes[0].className)[1]; responseText=RicoTranslate.getPhraseById(phraseId,this.options.RecordName);