Modification based on comments on github