Refactored subdomain.client.service.js
This commit is contained in:
parent
89c6dc43f8
commit
ac91913501
|
@ -2,8 +2,8 @@
|
|||
|
||||
angular.module('core').factory('subdomain', ['$location', function ($location) {
|
||||
var host = $location.host();
|
||||
if (host.indexOf('.') < 0)
|
||||
if (host.indexOf('.') < 0) {
|
||||
return null;
|
||||
else
|
||||
return host.split('.')[0];
|
||||
}
|
||||
return host.split('.')[0];
|
||||
}]);
|
||||
|
|
Loading…
Reference in a new issue