[Demonstration 1]

[Buggy Method]
public static Method getMethodFromTarget(JoinPoint joinPoint) {
    Method method = null;
    if (joinPoint.getSignature() instanceof MethodSignature) {
        MethodSignature signature = (MethodSignature) joinPoint.getSignature();
        method = getDeclaredMethod(joinPoint.getTarget().getClass(), signature.getName(), getParameterTypes(joinPoint));
    }
    return method;
}

[Buggy Hunk]
method = getDeclaredMethod(joinPoint.getTarget().getClass(), signature.getName(),

[Patch]
method = getDeclaredMethod(signature.getDeclaringType().getClass(), signature.getName(),

[Demonstration 2]

[Buggy Method]
public void setTotal(final int total) {
    boolean needToClear = total != this.total;
    this.total = total;
    currentPage = 1;
    if ($initialized && needToClear) {
        this.clear();
        init();
    }
}

[Buggy Hunk]
if ($initialized && needToClear) {

[Patch]
if (calcInitialized && needToClear) {

[Demonstration 3]

[Buggy Method]
public void toggle(boolean toggle) {
    int color;
    if (toggle) {
        color = mActiveColor;
    } else {
        color = ResourcesCompat.getColor(getResources(), R.color.defaultNotActiveCircle, null);
    }
    mDrawable.setStroke(getMeasuredHeight() / 30, color);
}

[Buggy Hunk]
public void toggle(boolean toggle) {

[Patch]
private void toggle(boolean toggle) {