mirror of
https://github.com/showdownjs/showdown.git
synced 2024-03-22 13:30:55 +08:00
Added support for ender.
- It defines everything to look and act like node, which makes `require('fs')` throw an exception (unloaded module).
This commit is contained in:
parent
2e102c72b2
commit
1d3f306fb8
|
@ -117,8 +117,11 @@ var g_output_modifiers = [];
|
|||
// Automatic Extension Loading (node only):
|
||||
//
|
||||
|
||||
if (typeof module !== 'undefind' && typeof exports !== 'undefined' && typeof require !== 'undefind') {
|
||||
var fs = require('fs');
|
||||
if (typeof module !== 'undefined' && typeof exports !== 'undefined' && typeof require !== 'undefined') {
|
||||
var fs;
|
||||
try {
|
||||
fs = require('fs');
|
||||
} catch(e) {}
|
||||
|
||||
if (fs) {
|
||||
// Search extensions folder
|
||||
|
|
Loading…
Reference in New Issue
Block a user