implement Giuli's change to master close #11