Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Fixes a bug in Adobe CEP where CEP confuses connected drives with local folders when the relative paths are the same. For instance "/Volumes/Users/username" and "/Users/username"
* Bug fix for the issue described at the link below.
* @link
function fixVolumePathBug(filepath) {
if ($.os.toLowerCase().indexOf('mac') === -1) return filepath;
var $HOME = new Folder('~/').fsName;
if (filepath.indexOf($HOME) > 0) {
var parts = filepath.split($HOME);
filepath = $HOME + '/' + parts.pop();
return filepath;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.