Buggy code:
public abstract class FormComponent < T > extends LabeledWebMarkupContainer implements IFormModelUpdateListener , IFormVisitorParticipant { private static final Logger logger = LoggerFactory . getLogger ( FormComponent . class ) ; public abstract static class AbstractVisitor implements FormComponent . IVisitor { public Object formComponent ( IFormVisitorParticipant component ) { } protected abstract void onFormComponent ( FormComponent < ? > formComponent ) { } } public static interface IVisitor { public Object formComponent ( IFormVisitorParticipant formComponent ) { } } private class MessageSource implements IErrorMessageSource { private final Set < String > triedKeys = new LinkedHashSet < String > ( ) ; public String getMessage ( String key ) { } private String prefix ( String prefix , String key ) { } private String getString ( Localizer localizer , String key , Component component ) { } public String substitute ( String string , Map < String , Object > vars ) throws IllegalStateException { } private Map < String , Object > addDefaultVars ( Map < String , Object > params ) { } private String getLabel ( ) { } } private final class RequiredStateChange extends Change { private static final long serialVersionUID = 1L ; private final boolean required = isRequired ( ) ; @ Override public void undo ( ) { } } private class ValidatableAdapter implements IValidatable < T > { public void error ( IValidationError error ) { } public T getValue ( ) { } public boolean isValid ( ) { } } public static String VALUE_SEPARATOR = ";" ; private static final String [ ] EMPTY_STRING_ARRAY = new String [ ] { "" } ; private static final short FLAG_PERSISTENT = FLAG_RESERVED2 ; private static final short FLAG_REQUIRED = FLAG_RESERVED3 ; private static final String NO_RAW_INPUT = "[-NO-RAW-INPUT-]" ; private static final long serialVersionUID = 1L ; protected static final short FLAG_CONVERT_EMPTY_INPUT_STRING_TO_NULL = FLAG_RESERVED1 ; public static final void visitFormComponentsPostOrder ( Component component , final FormComponent . IVisitor visitor ) { } private static final Object visitFormComponentsPostOrderHelper ( Component component , final FormComponent . IVisitor visitor ) { } public static final void visitComponentsPostOrder ( Component component , final Component . IVisitor < Component > visitor ) { } private static final Object visitComponentsPostOrderHelper ( Component component , final Component . IVisitor < Component > visitor ) { } private transient T convertedInput ; private String rawInput = FormComponent . NO_RAW_INPUT ; private String typeName ; private Object validators = null ; public FormComponent ( final String id ) { } public FormComponent ( final String id , IModel < T > model ) { } public final FormComponent < T > add ( final IValidator < T > validator ) { } public final FormComponent < T > add ( final IValidator < T > ... validators ) { } public boolean checkRequired ( ) { if ( isRequired ( ) ) { final String input = getInput ( ) ; <START_BUG> if ( ( input == null ) && ( ! ( isInputNullable ( ) ) ) ) { <END_BUG> return true ; } return ! ( Strings . isEmpty ( input ) ) ; } return true ; } public final void clearInput ( ) { } public void error ( IValidationError error ) { } public final T getConvertedInput ( ) { } public final void setConvertedInput ( T convertedInput ) { } public Form < ? > getForm ( ) { } public String getInput ( ) { } public String [ ] getInputAsArray ( ) { } public String getInputName ( ) { } public final String getRawInput ( ) { } @ SuppressWarnings ( "unchecked" ) public final Class < T > getType ( ) { } public String getValidatorKeyPrefix ( ) { } public final List < IValidator < T > > getValidators ( ) { } public final String getValue ( ) { } public final boolean hasRawInput ( ) { } public final void inputChanged ( ) { } public final void invalid ( ) { } public boolean isInputNullable ( ) { } public boolean isMultiPart ( ) { } public final boolean isPersistent ( ) { } public boolean isRequired ( ) { } public final boolean isValid ( ) { } public boolean processChildren ( ) { } public final void processInput ( ) { } public FormComponent < T > setLabel ( IModel < String > labelModel ) { } @ Deprecated public void setModelValue ( final String value ) { } public void setModelValue ( final String [ ] value ) { } public final FormComponent < T > setPersistent ( final boolean persistent ) { } public final FormComponent < T > setRequired ( final boolean required ) { } public final FormComponent < T > setType ( Class < ? > type ) { } public void updateModel ( ) { } public final void valid ( ) { } public void validate ( ) { } @ SuppressWarnings ( "unchecked" ) private void validators_add ( final IValidator < T > validator ) { } @ SuppressWarnings ( "unchecked" ) private IValidator < T > validators_get ( int index ) { } private int validators_size ( ) { } @ SuppressWarnings ( "unchecked" ) protected void convertInput ( ) { } private void reportValidationError ( ConversionException e , ValidationError error ) { } @ SuppressWarnings ( "unchecked" ) protected T convertValue ( String [ ] value ) throws ConversionException { } protected String getModelValue ( ) { } protected final int inputAsInt ( ) { } protected final int inputAsInt ( final int defaultValue ) { } protected final int [ ] inputAsIntArray ( ) { } @ Override protected void internalOnModelChanged ( ) { } @ Override protected void onComponentTag ( final ComponentTag tag ) { } @ Override protected void onDetach ( ) { } protected void onDisabled ( final ComponentTag tag ) { } protected void onInvalid ( ) { }

Fix:
if ( ( ( input == null ) && ( ! ( isInputNullable ( ) ) ) ) && ( ! ( FormComponent . isEnabledInHierarchy ( ) ) ) ) {