adjusted method so it passes the spec