simplified a little