แก้ coding style ภาค 10

This commit is contained in:
Pitchaya Boonsarngsuk
2018-03-22 16:40:27 +00:00
parent 400eab7e80
commit cd0f3687cb
14 changed files with 104 additions and 109 deletions

View File

@@ -5,7 +5,7 @@
* @param {array} properties - the properties of the nodes.
* @return {number} the distance between source and target nodes.
*/
function calculateManhattanDistance(source, target, properties, normArgs) {
function calculateManhattanDistance (source, target, properties, normArgs) {
var sum = 0.0,
cols = 0;
@@ -13,7 +13,7 @@ function calculateManhattanDistance(source, target, properties, normArgs) {
// Iterate through every column of data
for (var i = 0; i < properties.length; i++) {
property = properties[i];
if (property.toLowerCase() !== "class" && property.toLowerCase() !== "app" && property.toLowerCase() !== "user" && property.toLowerCase() !== "weekday") {
if (property.toLowerCase() !== 'class' && property.toLowerCase() !== 'app' && property.toLowerCase() !== 'user' && property.toLowerCase() !== 'weekday') {
var s = source[property],
t = target[property];