Pretty sure you can do these four lines more easily with:

```
self.code = kwargs.pop('code', 400)
```