Fixed the inventory registry field not trimming whitespace

This commit is contained in:
Erik Thuning 2024-02-08 15:38:54 +01:00
parent 1f33f73938
commit 4f8bc9486d

@ -164,7 +164,7 @@ class Ajax extends Responder {
} }
$product = null; $product = null;
try { try {
$product = new Product($_POST['serial'], 'serial'); $product = new Product(trim($_POST['serial']), 'serial');
} catch(Exception $e) { } catch(Exception $e) {
return new Failure('Ogiltigt serienummer.'); return new Failure('Ogiltigt serienummer.');
} }