Projet

Général

Profil

0001-grandlyon-street-sections-support-data-returning-nul.patch

Frédéric Péters, 11 juillet 2020 12:54

Télécharger (1,21 ko)

Voir les différences:

Subject: [PATCH] grandlyon street sections: support data returning null values
 (#45042)

 passerelle/contrib/grandlyon_streetsections/models.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
passerelle/contrib/grandlyon_streetsections/models.py
117 117
            for attribute in ('bornemindroite', 'bornemingauche',
118 118
                              'bornemaxdroite', 'bornemaxgauche',
119 119
                              'gid'):
120
                if value.get(attribute) == 'None':
120
                if value.get(attribute) in (None, 'None'):
121
                    # data.grandlyon returned 'None' as a string at at time
121 122
                    if 'min' in attribute:
122 123
                        attribute_value = 0
123 124
                    elif 'max' in attribute:
124
-