Contact Form: state and postcode with leading and trailing spaces could use strip

Create issue
Issue #1224 new
Former user created an issue

In the ContactInfoForm class under satchmo_store/contact/ you could use a string strip to remove leading and trailing spaces that way ppl who paste in addresses will not get validation errors.

def clean_ship_postal_code(self): code = self.ship_charfield_clean('postal_code') if code: code = code.strip()

There may be other places this would be helpful.

Comments (0)

  1. Log in to comment