From e25e519e7ae29a4dd80deed93b95f8f19fcb1814 Mon Sep 17 00:00:00 2001 From: Terranom674 Date: Mon, 17 Aug 2026 21:32:09 +0200 Subject: [PATCH] Run productive API sync in Piwigo admin context --- include/nc_productive_ws.inc.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/nc_productive_ws.inc.php b/include/nc_productive_ws.inc.php index cb11c53..b0f2005 100644 --- a/include/nc_productive_ws.inc.php +++ b/include/nc_productive_ws.inc.php @@ -59,6 +59,11 @@ function bratonien_tools_ws_nc_sync_productive($params, &$service) try { + if (!defined('IN_ADMIN')) + { + define('IN_ADMIN', true); + } + $_SERVER['REQUEST_METHOD'] = 'POST'; $_GET = array( 'page' => 'site_update',