function bfox_bp_plans_save_checks()
{
    if (isset($_POST['bible_reading_save_checks'])) {
        global $bp;
        $old_checks = explode(',', $_POST['bible_reading_plan_old_checks']);
        $checks = (array) $_POST['bible_reading_plan_checkbox'];
        // If checked before, but not now delete
        $remove_readings = bfox_bp_plans_parse_checks(array_diff($old_checks, $checks));
        // If not checked before, but checked now add
        $add_readings = bfox_bp_plans_parse_checks(array_diff($checks, $old_checks));
        $schedule_ids = array_unique(array_merge(array_keys($remove_readings), array_keys($add_readings)));
        BfoxReadingSchedule::remove_progress($remove_readings, $bp->loggedin_user->id);
        BfoxReadingSchedule::add_progress($add_readings, $bp->loggedin_user->id);
        bp_core_redirect(wp_get_referer());
    }
}