Update swagger.py

This needs checking.  Make sure you have a test suite written with some test data
Merge pull request #2 from ams-bjones/patch-1

Update swagger.py