Fixed bug in is.empty