fixed bug, if under tenant account base_url() is replaced by tenant_url(); fixed name triming issues