Limitation of input variables to prevent crash