diff --git a/include/management/snapshot/class_SnapshotAttribute.inc b/include/management/snapshot/class_SnapshotAttribute.inc
index d09e493237b2b5a623734d25e83b00dc1ac1b04d..7ea5e2423fb8a0aa242c4e06031a6dccf199abb8 100755
--- a/include/management/snapshot/class_SnapshotAttribute.inc
+++ b/include/management/snapshot/class_SnapshotAttribute.inc
@@ -122,7 +122,7 @@ class SnapshotsAttribute extends OrderedArrayAttribute
     }
     if (preg_match('/^'.$id.'_restore_/', (string) $postValue)) {
       $key = preg_replace('/^'.$id.'_restore_/', '', (string) $postValue);
-      $key = preg_replace('/_[xy]$/', '', $key);
+      $key = preg_replace('/_[xy]$/', '', (string) $key);
 
       $this->plugin->triggerRestore($this->value[$key]['dn']);
       return TRUE;