rename R.size and handle null/undefined argument