Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 65f5e85

Browse files
committed
chore(ngdoc): fix deprecated node api path.existsSync -> fs.existsSync
1 parent 63c1e5b commit 65f5e85

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/src/ngdoc.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ Doc.prototype = {
145145
example.addSource(name, content);
146146
});
147147
content.replace(/<file\s+src="([^"]+)"(?:\s+tag="([^"]+)")?(?:\s+name="([^"]+)")?\s*\/?>/gmi, function(_, file, tag, name) {
148-
if(fspath.existsSync(file)) {
148+
if(fs.existsSync(file)) {
149149
var content = fs.readFileSync(file, 'utf8');
150150
if(content && content.length > 0) {
151151
if(tag && tag.length > 0) {
@@ -160,7 +160,7 @@ Doc.prototype = {
160160
return placeholder(example.toHtml());
161161
}).
162162
replace(/(?:\*\s+)?<file.+?src="([^"]+)"(?:\s+tag="([^"]+)")?\s*\/?>/i, function(_, file, tag) {
163-
if(fspath.existsSync(file)) {
163+
if(fs.existsSync(file)) {
164164
var content = fs.readFileSync(file, 'utf8');
165165
if(tag && tag.length > 0) {
166166
content = extractInlineDocCode(content, tag);
@@ -361,7 +361,7 @@ Doc.prototype = {
361361

362362
html_usage_parameters: function(dom) {
363363
var self = this;
364-
var params = this.param ? this.param : [];
364+
var params = this.param ? this.param : [];
365365
if(params.length > 0) {
366366
dom.html('<h2 id="parameters">Parameters</h2>');
367367
dom.html('<table class="variables-matrix table table-bordered table-striped">');

0 commit comments

Comments
 (0)