$this->EE->db->select('module_id');
$query = $this->EE->db->get_where('modules', array('module_name' => 'Blogger_api'));
this looking for Blogger_api moduel In modules table in my database.
In my database there is no Blogger_api moduel in modules table so it’s return nothing to module_id.
when execute the next lines $query->row(‘module_id’) for some reason return array().
so I add add row to the modules table In my database with Blogger_api value in module_name column.
when I did that the $query->row(‘module_id’) return value and the upgrade done successfully.
I don’t remove any folder.
so I belive there is somthing must change in this code like:
if(!empty($query->row(‘module_id’)) {
$this->EE->db->where('module_id', $query->row('module_id'));
$this->EE->db->delete('module_member_groups');
}