~donadigo/pantheon-files/fix-get-filter-name

« back to all changes in this revision

Viewing changes to libcore/FileUtils.vala

* Show user bookmarks even when running as root
* Only show local folders in sidebar while root

Show diffs side-by-side

added added

removed removed

Lines of Context:
203
203
        if (path.length > 0) {
204
204
            if (scheme == "" && path.has_prefix ("/~/")) {
205
205
                sb.erase (0, 2);
206
 
                sb.prepend (Environment.get_home_dir ());
 
206
                sb.prepend (Eel.get_real_user_home ());
207
207
            }
208
208
        }
209
209
 
238
238
    public void split_protocol_from_path (string path, out string protocol, out string new_path) {
239
239
        protocol = "";
240
240
        new_path = path.dup ();
241
 
 
242
241
        string[] explode_protocol = new_path.split ("://");
 
242
 
243
243
        if (explode_protocol.length > 2) {
244
244
            new_path = "";
245
245
            return;