Adding sanity checks