Indeed the code looks strange. I'll improve it now. On Tue, Oct 19, 2010 at 5:46 PM, richard emberson < richard.ember...@gmail.com> wrote:
> > > I am simply in the process of looking into Wicket; reading one > of the Wicket books, lurking on the mailing list and reviewing > the code and comments. > I have not yet determined at what level I might become involved > with Java Wicket. > The code in this particular message thread I did not grok, so > I asked about it. > > Thanks. > > Richard > > > On 10/19/2010 07:58 AM, Martin Grigorov wrote: > >> On Tue, Oct 19, 2010 at 4:40 PM, richard emberson< >> richard.ember...@gmail.com> wrote: >> >> I've submitted such items to the dev list and got no reply. >>> >>> Hm, I don't remember seeing this in d...@. But I don't remember many >> other >> things too :-) >> >> At least here some knowledgeable "user" may look at the code >>> and provide feedback. >>> >> >> File it as a ticket in Jira and it will definitely get attention ;-) >> Complemented with a patch would be lovely! >> >> >>> >>> On 10/19/2010 07:30 AM, John Owen wrote: >>> >>> Shouldn't this be on the dev mailing list instead? >>>> >>>> -----Original Message----- >>>> From: richard emberson [mailto:richard.ember...@gmail.com] >>>> Sent: Monday, October 18, 2010 8:50 PM >>>> To: users@wicket.apache.org >>>> Subject: code review: >>>> org.apache.wicket.pageStore.AsynchronousDataStore.removeData >>>> >>>> org.apache.wicket.pageStore.AsynchronousDataStore.removeData >>>> >>>> A little code review please: >>>> >>>> In org.apache.wicket.pageStore.AsynchronousDataStore >>>> >>>> public void removeData(final String sessionId, final int id) >>>> { >>>> synchronized (WRITE_LOCK) >>>> { >>>> String key = getKey(sessionId, id); >>>> if (key != null) >>>> { >>>> entryMap.remove(key); >>>> } >>>> Entry entry = entryMap.get(key); >>>> if (entry != null) >>>> { >>>> entries.remove(entry); >>>> } >>>> } >>>> dataStore.removeData(sessionId, id); >>>> } >>>> >>>> After removing the Entry from the entryMap, why is there >>>> an attempt to get the Entry? >>>> Is the "get" there for the case when the key is null? >>>> From the getKey code it does not look like the key will >>>> ever be null. >>>> >>>> This code is in apache-wicket-1.5-M2.1 >>>> >>>> Richard >>>> >>>> >>>> -- >>> Quis custodiet ipsos custodes >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>> For additional commands, e-mail: users-h...@wicket.apache.org >>> >>> >>> >> > -- > Quis custodiet ipsos custodes > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > >