@@ -37,7 +37,7 @@ public class ValidateEntry {
3737
3838 public static final String ACTIVITY_VERB_POST = "post" ;
3939
40- private static Logger logger = Logger .getLogger (ValidateEntry .class );
40+ private static Logger LOGGER = Logger .getLogger (ValidateEntry .class );
4141
4242 private Element entry ;
4343
@@ -88,13 +88,13 @@ public boolean isValid() throws NodeStoreException {
8888 if ((id == null ) || (true == id .getText ().isEmpty ())) {
8989 if (null != id )
9090 id .detach ();
91- logger .debug ("ID of the entry was missing. We add a default one to it: 1" );
91+ LOGGER .debug ("ID of the entry was missing. We add a default one to it: 1" );
9292 this .entry .addElement ("id" ).setText ("1" );
9393 }
9494
9595 Element title = this .entry .element ("title" );
9696 if (null == title ) {
97- logger .debug ("Title of the entry was missing. We add a default one to it: 'Post'." );
97+ LOGGER .debug ("Title of the entry was missing. We add a default one to it: 'Post'." );
9898 title = this .entry .addElement ("title" );
9999 title .setText ("Post" );
100100 }
@@ -121,14 +121,15 @@ public boolean isValid() throws NodeStoreException {
121121 if (null == updated ) {
122122
123123 String updateTime = Conf .formatDate (new Date ());
124- logger .debug ("Update of the entry was missing. We add a default one to it: '"
124+ LOGGER .debug ("Update of the entry was missing. We add a default one to it: '"
125125 + updateTime + "'." );
126126 this .entry .addElement ("updated" ).setText (updateTime );
127127 }
128128
129129 this .geoloc = this .entry .element ("geoloc" );
130130
131131 Element reply = this .entry .element ("in-reply-to" );
132+
132133 if ((null != reply ) && (false == validateInReplyToElement (reply ))) {
133134 return false ;
134135 }
@@ -238,7 +239,7 @@ private boolean validateInReplyToElement(Element reply) throws NodeStoreExceptio
238239 return false ;
239240 }
240241 if (null != nodeItem .getInReplyTo ()) {
241- logger .error ("User is attempting to reply to a reply" );
242+ LOGGER .error ("User is attempting to reply to a reply" );
242243 this .errorMessage = MAX_THREAD_DEPTH_EXCEEDED ;
243244 return false ;
244245 }
0 commit comments