minor change
added security check