Answers.Body: <p>This is fixed by <a href="https://github.com/civicrm/civicrm-core/pull/25515/files" rel="nofollow noreferrer">https://github.com/civicrm/civicrm-core/pull/25515/files</a> in 5.60.</p>
  <pre><code>--- a/CRM/Contact/Page/AJAX.php
  +++ b/CRM/Contact/Page/AJAX.php
  @@ -483,7 +483,7 @@ public static function buildSubTypes() {
     }
   
     public static function buildDedupeRules() {
  -    $contactType = CRM_Utils_Request::retrieve('parentId', 'Positive');
  +    $contactType = CRM_Utils_Request::retrieve('parentId', 'String');
       $dedupeRules = CRM_Dedupe_BAO_DedupeRuleGroup::getByType($contactType);
   
       CRM_Utils_JSON::output($dedupeRules);
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-03-29T16:36:43.120Z
Answers.LastActivityDate: 2023-03-29T16:36:43.120Z
Answers.UserDisplayName: Demerit
Body: <p>Wordpress 6.1.1, Civi 5.59.4</p>
  <p>I have been getting the error &quot;Mismatched contact type.&quot; which is possibly linked to this: <a href="https://lab.civicrm.org/dev/core/-/issues/3927" rel="nofollow noreferrer">https://lab.civicrm.org/dev/core/-/issues/3927</a> but that appears patched since 5.54</p>
  <p>I cannot replicate in demo master.</p>
  <p>However I noticed that the dedupe rule options do not change based on contact type selection, they all show up.</p>
  <p><a href="https://i.sstatic.net/YqAbI.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/YqAbI.png" alt="enter image description here" /></a></p>
  <p>When I select the right dedupe rule - it imports without issue.</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2023-03-29T16:12:05.040Z
Comments.Text: I've seen that dedupe dropdown problem before but can't remember where. Will see if I can find.
Comments.UserDisplayName: Demerit
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2023-03-29T16:25:03.723Z
Comments.Text: I found the site, but I never resolved it, I just updated the labels so it was clear which contact types they applied to. For the record that site is 5.57.
Comments.UserDisplayName: Demerit
Tags: <contacts><import><data-import>
Title: Why am I getting "Mismatched contact type." when I try to import any contacts?
ThreadText: # Why am I getting "Mismatched contact type." when I try to import any contacts?
  
  (Asked by: username_0 on 2023-03-28)
  
  Wordpress 6.1.1, Civi 5.59.4
  
  I have been getting the error "Mismatched contact type." which is possibly linked to this: <https://lab.civicrm.org/dev/core/-/issues/3927> but that appears patched since 5.54
  
  I cannot replicate in demo master.
  
  However I noticed that the dedupe rule options do not change based on contact type selection, they all show up.
  
  [![enter image description here](https://i.sstatic.net/YqAbI.png)](https://i.sstatic.net/YqAbI.png)
  
  When I select the right dedupe rule - it imports without issue.
  
  **Tags:** contacts, import, data-import
  
  > **Comments:**
  > **username_1**: I've seen that dedupe dropdown problem before but can't remember where. Will see if I can find.  
  > **username_1**: I found the site, but I never resolved it, I just updated the labels so it was clear which contact types they applied to. For the record that site is 5.57.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2023-03-29. Score: 2 | Accepted answer
  
  This is fixed by <https://github.com/civicrm/civicrm-core/pull/25515/files> in 5.60.
  
  ```
  --- a/CRM/Contact/Page/AJAX.php
  +++ b/CRM/Contact/Page/AJAX.php
  @@ -483,7 +483,7 @@ public static function buildSubTypes() {
     }
   
     public static function buildDedupeRules() {
  -    $contactType = CRM_Utils_Request::retrieve('parentId', 'Positive');
  +    $contactType = CRM_Utils_Request::retrieve('parentId', 'String');
       $dedupeRules = CRM_Dedupe_BAO_DedupeRuleGroup::getByType($contactType);
   
       CRM_Utils_JSON::output($dedupeRules);
  
  ```
  
  
  ---
  
  