fixed issue when single entity is provided for the from method