diff --git a/jquery.serialize-object.js b/jquery.serialize-object.js index 6b33f37..4e8fdd2 100644 --- a/jquery.serialize-object.js +++ b/jquery.serialize-object.js @@ -84,6 +84,8 @@ switch ($('[name="' + pair.name + '"]', $form).attr("type")) { case "checkbox": return pair.value === "on" ? true : pair.value; + case "number": + return pair.value = parseInt(pair.value); default: return pair.value; }