Fixing error in store_data check for empty table.