|
Last change
on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 11 days ago |
|
Fix frontend appearance
|
-
Property mode
set to
100644
|
|
File size:
290 bytes
|
| Line | |
|---|
| 1 | 'use strict';
|
|---|
| 2 | const path = require('path');
|
|---|
| 3 |
|
|---|
| 4 | module.exports = (childPath, parentPath) => {
|
|---|
| 5 | const relation = path.relative(parentPath, childPath);
|
|---|
| 6 | return Boolean(
|
|---|
| 7 | relation &&
|
|---|
| 8 | relation !== '..' &&
|
|---|
| 9 | !relation.startsWith(`..${path.sep}`) &&
|
|---|
| 10 | relation !== path.resolve(childPath)
|
|---|
| 11 | );
|
|---|
| 12 | };
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.