prevent notices & better way of getting 'views' from meta

previous code made every first post view display a notice