feat: live Runware model sync with 24h cache and Sync Now button (v0.15.0)
Replace hardcoded model registry with live-sync system. New PRAutoBlogger_Runware_Model_Catalog class fetches the Runware model catalog daily, caches in WP options (24h TTL), and falls back to the hardcoded 15-model list if the API is unavailable. Sync Now button in PRAdmin for on-demand refresh. Eliminates the drift that caused silent model fallback bugs (v0.13.8, v0.14.0).
This commit is contained in:
@@ -130,6 +130,11 @@ class PRAutoBlogger_Activator {
|
||||
wp_schedule_event( $tomorrow, 'daily', 'prautoblogger_reap_orphan_research_rows' );
|
||||
}
|
||||
}
|
||||
|
||||
// v0.15.0: daily Runware model catalog sync.
|
||||
if ( ! wp_next_scheduled( 'prautoblogger_sync_runware_models' ) ) {
|
||||
wp_schedule_event( time() + HOUR_IN_SECONDS, 'daily', 'prautoblogger_sync_runware_models' );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user