Download & Extend

Do not check for user default domain on domain geolocalization and domain user default module menu callback urls

Project:Domain User Default
Version:6.x-1.x-dev
Component:Code
Category:bug report
Priority:critical
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

Do not check for user default domain on domain geolocalization and domain user default module menu callback urls, this results in user entered zip code/radius being overwritten by domain defaults.

Comments

#1

Patch attached

AttachmentSize
domain_user_default.module-ignore-module-paths.patch 4.82 KB

#2

I've attached a patch that should accomplish the same thing as the patch in #1. It creates a new function for determining internal paths, and then simply returns out of the init hook for internal paths. If this works, I'll apply it to CVS.

AttachmentSize
domain_user_default.module.ignore-module-paths.patch 1.53 KB

#3

Actually I've discovered that you'll need the $user object containing user default domain/geolocalization data even when it is an internal path eg. it should be loaded before check for internal path is performed.

Also when devel module is enabled there's a few more paths to avoid loading user default on; it might be a good idea to make this set a user configurable setting.

#4

Status:needs review» needs work

In my case I'm directly embedding the static form into content and this patch in #2, this part to precise:
if ($path != $_GET['q']) {
// Match path or alias.
$matches = $matches || drupal_match_path($_GET['q'], $internal_paths);
}
will cause form callback for 'domain_geolocalization_search_static_form' to fail.

#5

I don't quite understand why checking for an alias will cause a form callback to fail...are the internal paths being aliased? And if so, why would /not/ redirecting break the callback?

Is there a simple set of steps to reproduce this?

#6

Status:needs work» fixed

This has been working for a while but I never followed up on it. Patch from #2 committed.

#7

Status:fixed» closed (fixed)

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