mirror of
https://github.com/EDCD/coriolis.git
synced 2025-12-09 06:43:24 +00:00
Linting fixes
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
angular.module('shipyard').service('Components', ['lodash', 'ComponentsDB', 'ShipsDB', 'ComponentSet', function (_, C, Ships, ComponentSet) {
|
||||
angular.module('shipyard').service('Components', ['lodash', 'ComponentsDB', 'ShipsDB', 'ComponentSet', function(_, C, Ships, ComponentSet) {
|
||||
|
||||
this.cargoScoop = function() {
|
||||
return { name: 'Cargo Hatch', class: 1, rating: 'H', power: 0.6};
|
||||
return { name: 'Cargo Hatch', class: 1, rating: 'H', power: 0.6 };
|
||||
};
|
||||
|
||||
this.common = function (typeIndex, componentId) {
|
||||
this.common = function(typeIndex, componentId) {
|
||||
return C.common[typeIndex][componentId];
|
||||
};
|
||||
|
||||
@@ -12,7 +12,7 @@ angular.module('shipyard').service('Components', ['lodash', 'ComponentsDB', 'Shi
|
||||
for (var n in C.hardpoints) {
|
||||
var group = C.hardpoints[n];
|
||||
for (var i = 0; i < group.length; i++) {
|
||||
if (group[i].id == id) {
|
||||
if (group[i].id === id) {
|
||||
return group[i];
|
||||
}
|
||||
}
|
||||
@@ -24,7 +24,7 @@ angular.module('shipyard').service('Components', ['lodash', 'ComponentsDB', 'Shi
|
||||
for (var n in C.internal) {
|
||||
var group = C.internal[n];
|
||||
for (var i = 0; i < group.length; i++) {
|
||||
if (group[i].id == id) {
|
||||
if (group[i].id === id) {
|
||||
return group[i];
|
||||
}
|
||||
}
|
||||
@@ -49,9 +49,9 @@ angular.module('shipyard').service('Components', ['lodash', 'ComponentsDB', 'Shi
|
||||
* @param {string} shipId Unique ship Id/Key
|
||||
* @return {ComponentSet} The set of components the ship can install
|
||||
*/
|
||||
this.forShip = function (shipId) {
|
||||
this.forShip = function(shipId) {
|
||||
var ship = Ships[shipId];
|
||||
return new ComponentSet(C, ship.properties.mass + 5, ship.slots.common, ship.slots.internal[0], ship.slots.hardpoints[0]);
|
||||
};
|
||||
|
||||
}]);
|
||||
}]);
|
||||
|
||||
Reference in New Issue
Block a user