Skip to content

Commit 54dbe87

Browse files
committed
Avoid unnecessary variable
1 parent 592cd21 commit 54dbe87

File tree

1 file changed

+2
-5
lines changed
  • lib/node_modules/@stdlib/assert/has-define-property-support/lib

1 file changed

+2
-5
lines changed

lib/node_modules/@stdlib/assert/has-define-property-support/lib/main.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,13 @@ var defineProperty = require( './define_property.js' );
3535
* // returns <boolean>
3636
*/
3737
function hasDefinePropertySupport() {
38-
var bool;
39-
4038
// Test basic support...
4139
try {
4240
defineProperty( {}, 'x', {} );
43-
bool = true;
41+
return true;
4442
} catch ( err ) { // eslint-disable-line no-unused-vars
45-
bool = false;
43+
return false;
4644
}
47-
return bool;
4845
}
4946

5047

0 commit comments

Comments
 (0)