changes to pin method