|
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:
292 bytes
|
| Line | |
|---|
| 1 | var rimraf = require('rimraf').sync;
|
|---|
| 2 | var fs = require('fs');
|
|---|
| 3 |
|
|---|
| 4 | module.exports = function del(file) {
|
|---|
| 5 | if (fs.existsSync(file)) {
|
|---|
| 6 | //if rimraf doesn't throw then the file has been deleted or didn't exist
|
|---|
| 7 | rimraf(file, {
|
|---|
| 8 | glob: false,
|
|---|
| 9 | });
|
|---|
| 10 | return true;
|
|---|
| 11 | }
|
|---|
| 12 | return false;
|
|---|
| 13 | };
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.