replaced 'not empty' wit 'isset' to handle variables equal to 0