Skip to content

Commit

Permalink
changed to os.tmpdir()
Browse files Browse the repository at this point in the history
  • Loading branch information
SGoerzen committed Aug 27, 2019
1 parent 261eb34 commit 95e30b9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ var debug = require('debug')('gify');
var mkdirp = require('mkdirp');
var uid = require('uid2');
var path = require('path');
var os = require('os');

/**
* Expose `gify()`.
Expand Down Expand Up @@ -62,8 +63,7 @@ function gify(input, output, opts, fn) {

// tmpfile(s)
var id = uid(10);
const tmpFolder = process.platform === 'win32' ? '%temp%' : '/tmp/';
var dir = path.resolve(tmpFolder + id);
var dir = path.resolve(os.tmpdir() + id);
var tmp = path.join(dir, '/%04d.png');

// escape paths
Expand Down

0 comments on commit 95e30b9

Please sign in to comment.