Index: /controller/wpsg_ShopController.class.php
===================================================================
--- /controller/wpsg_ShopController.class.php	(revision 7981)
+++ /controller/wpsg_ShopController.class.php	(revision 7982)
@@ -690,6 +690,5 @@
 		public function checkEscape() {
  
-			/*
-			if (strlen($_GET['wpsg_quotecheck']) > 7) {
+			if (isset($_GET['wpsg_quotecheck']) && strlen($_GET['wpsg_quotecheck']) > 7) {
 
 				$_POST      = array_map('stripslashes_deep', $_POST);
@@ -702,5 +701,4 @@
 
 			}
-			*/
 
 		} // public function checkEscape()
Index: /mods/mod_abo/wpsg_abo.php
===================================================================
--- /mods/mod_abo/wpsg_abo.php	(revision 7981)
+++ /mods/mod_abo/wpsg_abo.php	(revision 7982)
@@ -181,5 +181,5 @@
             $strLimit = "";
 
-            if (wpsg_isSizedArray($arFilter['limit'])) $strLimit = "LIMIT ".wpsg_q($arFilter['limit'][0]).", ".wpsg_q($arFilter['limit'][1]);
+            if (wpsg_isSizedArray($arFilter['limit']) && !wpsg_isSizedInt($arFilter['state'])) $strLimit = "LIMIT ".wpsg_q($arFilter['limit'][0]).", ".wpsg_q($arFilter['limit'][1]);
 
             $strQuery = "
@@ -225,4 +225,11 @@
                     
                 }
+				
+				if (wpsg_isSizedArray($arFilter['limit'])) {
+					
+					$arAboID = array_slice($arAboID, intval($arFilter['limit'][0]), intval($arFilter['limit'][1]));
+					
+				}
+					
                 
             }
@@ -256,5 +263,5 @@
                     
                     $oAbo = wpsg_abo::getInstance($abo_id);
-
+ 
                     if ($oAbo->getState() !== intval($arFilter['state'])) unset($arAbo[$k]);
                     
Index: /mods/wpsg_mod_abo.class.php
===================================================================
--- /mods/wpsg_mod_abo.class.php	(revision 7981)
+++ /mods/wpsg_mod_abo.class.php	(revision 7982)
@@ -168,7 +168,8 @@
 
 			    $filter_state = $this->shop->view['arFilter'];
-			    $filter_state['state'] = $state_key;
+			    $filter_state['state'] = intval($state_key);
+				
 			    $count = wpsg_abo::count($filter_state);
-
+				
 			    if ($count > 0) {
 
@@ -180,5 +181,5 @@
                 }
 
-            }
+            } 
 
 			$this->shop->view['countAll'] = wpsg_abo::count($this->shop->view['arFilter']);
@@ -195,5 +196,5 @@
 
 			$this->shop->view['arData'] = wpsg_abo::find($this->shop->view['arFilter']);
-
+			
 			$this->shop->view['cdate_years'] = $this->db->fetchAssocField("SELECT DISTINCT DATE_FORMAT(`cdate`, '%Y') FROM `".WPSG_TBL_ORDER."` ORDER BY `cdate` ASC ");
 
@@ -535,4 +536,11 @@
 		public function cron() {
 
+			date_default_timezone_set('Europe/Berlin');
+			
+            //$d1 = date_create('2022-04-20 12:05:00');
+			//$d2 = date_create('2022-04-20 12:00:00'); // NOW
+			//echo " = ".date_diff($d1, $d2)->format('%r%a');
+			//die();
+			
 			$handledAboIDs = [];
 
@@ -563,9 +571,9 @@
 
                 $wpsg_mod_abo_autoexpire_informationtime = intval($this->getSetting('wpsg_mod_abo_autoexpire_informationtime', $product_id)); // Benachrichtigung
-                $interval = intval(date_diff(date_create($a['expiration']), date_create(date('Y-m-d')))->format('%r%a')); // Tage bis zum auslaufen
+                $interval = intval(date_diff(date_create($a['expiration']), date_create(date('Y-m-d H:i:s')))->format('%r%a')); // Tage bis zum auslaufen
 
 	            // Positiv NOW() > Auslauf
-
-                if ($wpsg_mod_abo_autoexpire_informationtime > 0 && abs($interval) <= $wpsg_mod_abo_autoexpire_informationtime && $interval < 0) {
+ 	            
+                if ($wpsg_mod_abo_autoexpire_informationtime > 0 && abs($interval) < $wpsg_mod_abo_autoexpire_informationtime && $interval <= 0) {
 
                     $wpsg_mod_abo_expiremode = $this->getSetting('wpsg_mod_abo_premode', $product_id);
@@ -582,5 +590,5 @@
 
                     } else if ($wpsg_mod_abo_expiremode === self::EXPIRE_AUTO) {
-
+						
                     	$this->autoExtendOrder($a['order_id'], $a['order_product_id']);
 
@@ -592,5 +600,5 @@
 
             }
-
+ 
 			$arAboExpiration = $this->db->fetchAssoc("
 				SELECT
@@ -1096,5 +1104,5 @@
             if ($tDate <= 0) throw new \wpsg\Exception(__('Kein Datum ÃŒbergeben.', 'wpsg'));
 
-            $tDate += 3600; // TODO: KlÃ€ren warum das nicht richtig von x-editable geparsed wird, find es jetzt nicht
+            $tDate += (3600 * get_option('gmt_offset')); // TODO: KlÃ€ren warum das nicht richtig von x-editable geparsed wird, find es jetzt nicht
 
             $this->db->UpdateQuery(WPSG_TBL_ABO, [
Index: /wpshopgermany.php
===================================================================
--- /wpshopgermany.php	(revision 7981)
+++ /wpshopgermany.php	(revision 7982)
@@ -177,6 +177,5 @@
 
 	//Mediathek Neues Bild macht Probleme TODO: KlÃ€ren ob das noch nÃ¶tig ist
-	//$_GET['wpsg_quotecheck'] = '\"CHECK';
-	//if (($_REQUEST['action']??'') !== 'upload-attachment') $_GET['wpsg_quotecheck'] = '\"CHECK';
+	if (basename($_SERVER['SCRIPT_FILENAME']) !== 'upload.php' && ($_REQUEST['action']??'') !== 'upload-attachment') $_GET['wpsg_quotecheck'] = '\"CHECK';
 	
 	/** @var wpsg_db */
