`not []` evaluates to True and `not not []` negates that. It's fancy for

``` python
if paths[relpath]['medias']:
     ctx['settings']['zip_gallery'] = True
else:
     ctx['settings']['zip_gallery'] = False
```