You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

21 lines
388 B

  1. /*!
  2. * node-sass: lib/binding.js
  3. */
  4. var errors = require('./errors');
  5. /**
  6. * Require binding
  7. */
  8. module.exports = function(ext) {
  9. if (!ext.hasBinary(ext.getBinaryPath())) {
  10. if (!ext.isSupportedEnvironment()) {
  11. throw new Error(errors.unsupportedEnvironment());
  12. } else {
  13. throw new Error(errors.missingBinary());
  14. }
  15. }
  16. return require(ext.getBinaryPath());
  17. };