#vulnerable code 
                             @Override
	public Object getAsObject(FacesContext context, UIComponent component, String submittedValue) {
		String string = submittedValue;

		if (!isEmpty(string)) {
			DecimalFormat formatter = getFormatter();
			String symbol = getSymbol(formatter);

			if (!string.contains(symbol)) {
				string = PATTERN_NUMBER.matcher(formatter.format(0)).replaceAll(submittedValue);
			}
		}

		return super.getAsObject(context, component, string);
	} 
                            #location 10 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                             @Override
	public Object getAsObject(FacesContext context, UIComponent component, String submittedValue) {
		String string = submittedValue;

		if (!isEmpty(string)) {
			DecimalFormat formatter = getFormatter();

			if (formatter != null) {
				String symbol = getSymbol(formatter);

				if (!string.contains(symbol)) {
					string = PATTERN_NUMBER.matcher(formatter.format(0)).replaceAll(submittedValue);
				}
			}
		}

		return super.getAsObject(context, component, string);
	}