Media Browser Plus moving around JS file to different places silently and generates a missing paths in GMap module, see:
#1931138: Fixing all 'single marker' issues

Dump from debug:

-> media_browser_plus_move_file($tid = '2418', $file = class stdClass { public $fid = NULL; public $uri = 'public://js/gmap_markers.js'; public $filename = 'gmap_markers.js'; public $filemime = 'application/x-javascript'; public $uid = '1'; public $status = 1; public $timestamp = 1378829679; public $filesize = 4202; public $type = 'undefined'; public $field_folder = array ('und' => array (...)) }, $replace = 0, $save = FALSE) sites/all/modules/media_browser_plus/media_browser_plus.file.inc:22
-> file_unmanaged_move($source = 'public://js/gmap_markers.js', $destination = 'public://', $replace = 0) sites/all/modules/media_browser_plus/media_browser_plus.module:479
CommentFileSizeAuthor
#3 file-exclusions-2085857-1.patch1.47 KBjami3z
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jami3z’s picture

Any status on this? Should this be handled at the gmap end or MBP?

jami3z’s picture

After thinking about this I thought it might be a good thing to have the possibility to exclude certain files that you may not want to be moved by MBP. This would then solve this issue and possibly others that may arise from other modules with the same thing. Ill try and provide a patch.

jami3z’s picture

Issue summary: View changes
Status: Active » Needs review
FileSize
1.47 KB

Here is my patch!

kenorb’s picture

'filesnames' should be called 'filenames'.

kenorb’s picture

jami3z’s picture

Just found out my patch is incorrect and does not work properly. Check should be done in the file_presave function. Will provide revised patch (including spelling mistake @kenorb discovered)

cheers

das-peter’s picture

Hmm, this is wired. I don't think I fully understand the problem.
The concept is that MBP takes care of all files registered in the table file_managed, because well they should be managed.
If gmap_markers.js is registered in the table it will be handled by MBP.
However if it's not registered there MBP has to ignore it.

The question now is, is gmap_markers.js registered or not?
If it is I'd say its a bug in gmap.
if it isn't this is a bug in MBP.

thijsvdanker’s picture

@das-peter: I had the same problem and agree that it should be done right on gmap's side.
I've created a patch there that should sort this problem out.
https://drupal.org/node/2185395

thijsvdanker’s picture

izus’s picture

Status: Needs review » Fixed

the issue mentionned in #9 is solved, and so should be this issue's status

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.