diff --git a/eeschema/tools/sch_editor_control.cpp b/eeschema/tools/sch_editor_control.cpp index 369929fe80..7de722d71a 100644 --- a/eeschema/tools/sch_editor_control.cpp +++ b/eeschema/tools/sch_editor_control.cpp @@ -1962,7 +1962,7 @@ int SCH_EDITOR_CONTROL::Paste( const TOOL_EVENT& aEvent ) for( const SCH_SHEET_INSTANCE& pastedInstance : sheet->GetInstances() ) { - if( pastedInstance.m_ProjectName != m_frame->Prj().GetProjectName() ) + if( !hierarchy.HasPath( pastedInstance.m_Path ) ) instancesToRemove.push_back( pastedInstance.m_Path ); }