You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2014/08/01 19:23:40 UTC
[jira] [Commented] (TAP5-1941) Alerts component can fail with
ComponentEventException is dismiss event triggered outside of XHR request
(e.g., by web crawler)
[ https://issues.apache.org/jira/browse/TAP5-1941?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14082555#comment-14082555 ]
ASF subversion and git services commented on TAP5-1941:
-------------------------------------------------------
Commit 0d3c9bc950adcf837ae4378e2efe490763cc10fa in tapestry-5's branch refs/heads/master from [~hlship]
[ https://git-wip-us.apache.org/repos/asf?p=tapestry-5.git;h=0d3c9bc ]
TAP5-1941: Alerts component can fail with ComponentEventException is dismiss event triggered outside of XHR request (e.g., by web crawler)
> Alerts component can fail with ComponentEventException is dismiss event triggered outside of XHR request (e.g., by web crawler)
> -------------------------------------------------------------------------------------------------------------------------------
>
> Key: TAP5-1941
> URL: https://issues.apache.org/jira/browse/TAP5-1941
> Project: Tapestry 5
> Issue Type: Bug
> Components: tapestry-core
> Affects Versions: 5.3.3
> Reporter: Felix Gonschorek
> Assignee: Howard M. Lewis Ship
> Priority: Minor
> Fix For: 5.4
>
>
> The Alerts component does not check for request.isXHR() in the "onDismiss" event handler.
> Crawlers (Googlebot) send non-xhr requests to the "onDismiss" event-url and generate errors on my server, because the returned JSONObject is not a valid return value from an event handler.
> org.apache.tapestry5.runtime.ComponentEventException: A component event handler method returned the value {}. Return type org.apache.tapestry5.json.JSONObject can not be handled.
> A check for request.isXHR() and a conditional return value (null for non-ajax requests, the json object for ajax requests) should fix this.
> thanks!
--
This message was sent by Atlassian JIRA
(v6.2#6252)