trying to merge Nolan #111 and Camille's #121

But please check it ... I might have messed it up - I got lost at some stage...