Browse Source

fix lgtm.com alerts: nullness check using !== operator

details:
https://lgtm.com/projects/g/mrdoob/three.js/snapshot/dist-10110011-1494681683902/files/examples/js/loaders/MMDLoader.js#V430
https://lgtm.com/projects/g/mrdoob/three.js/snapshot/dist-10110011-1494681683902/files/examples/js/loaders/MMDLoader.js#V1589
https://lgtm.com/projects/g/mrdoob/three.js/snapshot/dist-10110011-1494681683902/files/examples/js/loaders/MMDLoader.js#V1631
Bas van Schaik 8 years ago
parent
commit
6aafd5eba9
1 changed files with 3 additions and 3 deletions
  1. 3 3
      examples/js/loaders/MMDLoader.js

+ 3 - 3
examples/js/loaders/MMDLoader.js

@@ -427,7 +427,7 @@ THREE.MMDLoader.prototype.pourVmdIntoCamera = function ( camera, vmd, name ) {
 
 		var clip = new THREE.AnimationClip( name === undefined ? THREE.Math.generateUUID() : name, -1, tracks );
 
-		if ( clip !== null ) {
+		if ( clip != null ) {
 
 			if ( camera.center === undefined ) camera.center = new THREE.Vector3( 0, 0, 0 );
 			if ( camera.animations === undefined ) camera.animations = [];
@@ -1586,7 +1586,7 @@ THREE.MMDLoader.prototype.createAnimation = function ( mesh, vmd, name ) {
 
 		var clip = new THREE.AnimationClip( name === undefined ? THREE.Math.generateUUID() : name, -1, tracks );
 
-		if ( clip !== null ) {
+		if ( clip != null ) {
 
 			if ( mesh.geometry.animations === undefined ) mesh.geometry.animations = [];
 			mesh.geometry.animations.push( clip );
@@ -1628,7 +1628,7 @@ THREE.MMDLoader.prototype.createAnimation = function ( mesh, vmd, name ) {
 
 		var clip = new THREE.AnimationClip( name === undefined ? THREE.Math.generateUUID() : name + 'Morph', -1, tracks );
 
-		if ( clip !== null ) {
+		if ( clip != null ) {
 
 			if ( mesh.geometry.animations === undefined ) mesh.geometry.animations = [];
 			mesh.geometry.animations.push( clip );