Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Newsletter template gets IndexOutOfBoundsException for the actionstoolbar.jsp

Avatar

Avatar
Validate 10
Level 2
doeringa
Level 2

Likes

3 likes

Total Posts

54 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 3
Boost 1
View profile

Avatar
Validate 10
Level 2
doeringa
Level 2

Likes

3 likes

Total Posts

54 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 3
Boost 1
View profile
doeringa
Level 2

15-10-2015

Hi, 

I want to create a custom newsletter template and use the available email emulator and toolbar. 

My setup: 

- newsletter template with sling:resourceType="myproject/renderers/newsletter"

-newsletter renderer with sling:resourceSuperType="/libs/mcm/components/newsletter/page" and a body.jsp with the same content as the geometrixx newsletter component (/apps/geometrixx/components/newsletterpage), I've only adjusted the paths of the includes. 

With all of this I get the following error message:

Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
    at java.util.LinkedList.checkElementIndex(Unknown Source)
    at java.util.LinkedList.remove(Unknown Source)
    at com.day.cq.wcm.api.components.Toolbar.remove(Toolbar.java:273)
    at org.apache.jsp.libs.mcm.components.newsletter.page.actionstoolbar_jsp._jspService(actionstoolbar_jsp.java:162)
    at org.apache.sling.scripting.jsp.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:502)
    ... 137 more

 

If I remove the include for the actionstoolbar.jsp , everything seems fine. 

Anybody experience this before? Or have an idea how I can make the actionstoolbar work (seems to be the only way to test, send and publish a newsletter)

Thanks, Alex

Accepted Solutions (0)

Answers (0)