[Demonstration 1]

[Buggy Method]
@Override
public Optional<IncrementalResultExporter> build(Context context) throws IncrementalExporterFactoryException, ConfigurationException {
    Preconditions.checkNotNull(context);
    RyaSubGraphExportParameters params = new RyaSubGraphExportParameters(context.getObserverConfiguration().toMap());
    if (params.getUseRyaSubGraphExporter()) {
        try {
            //Get FluoConfiguration from params
            FluoConfiguration conf = params.getFluoConfiguration();
            FluoClient fluo = new FluoClientImpl(conf);
            //Create exporter
            RyaSubGraphExporter exporter = new RyaSubGraphExporter(fluo);
            return Optional.of(exporter);
        } catch (Exception e) {
            throw new IncrementalExporterFactoryException("Could not initialize the RyaSubGraphExporter", e);
        }
    }
    return Optional.absent();
}

[Buggy Hunk]
FluoClient fluo = new FluoClientImpl(conf);

[Patch]
FluoClient fluo = FluoFactory.newClient(conf);

[Demonstration 2]

[Buggy Method]
public void updateOptions(Options options) {
    getState().options = options;
    Gson gson = new Gson();
    String json = gson.toJson(options);
    callFunction("updateOptions", json);
}

[Buggy Hunk]
getState().options = options;

[Patch]
getState().updates++;

[Demonstration 3]

[Buggy Method]
@Override
public Loader<Cursor> onCreateLoader(int id, Bundle args) {
    CursorLoader loader = new CursorLoader(getContext());
    loader.setUri(ChuckContentProvider.TRANSACTION_URI);
    if (currentFilter != null) {
        if (TextUtils.isDigitsOnly(currentFilter)) {
            loader.setSelection("responseCode LIKE ?");
            loader.setSelectionArgs(new String[] { currentFilter + "%" });
        } else {
            loader.setSelection("path LIKE ?");
            loader.setSelectionArgs(new String[] { "%" + currentFilter + "%" });
        }
    }
    loader.setSortOrder("requestDate DESC");
    return loader;
}

[Buggy Hunk]
if (currentFilter != null) {

[Patch]
if (!TextUtils.isEmpty(currentFilter)) {