fixed jade templates. updated max count