Error check on schema call.

Added comment with correct object return.