lingo: remove webservice URL trailing slash if necessary (#10347)
This commit is contained in:
parent
9f62013af4
commit
a140d0ffd0
|
@ -86,6 +86,11 @@ class Regie(models.Model):
|
|||
class Meta:
|
||||
verbose_name = _('Regie')
|
||||
|
||||
def save(self, *args, **kwargs):
|
||||
if self.webservice_url and self.webservice_url.endswith('/'):
|
||||
self.webservice_url = self.webservice_url.strip('/')
|
||||
super(Regie, self).save(*args, **kwargs)
|
||||
|
||||
def natural_key(self):
|
||||
return (self.slug,)
|
||||
|
||||
|
|
Loading…
Reference in New Issue