fix embedsOne error when embed instance is undefined or null

Signed-off-by: Clark Wang <clark.wangs@gmail.com>