Fixed code error (-1 -> None as default)