# `GSGlyph removeIncompatibleLayerContent:options:`

*Instance Method*

Clears the shapes of active layers whose selected aspects do not match the first layer.

## Declaration

```swift
func removeIncompatibleLayerContent(_ fontMasterIds: [String], options: GSLayerCompareFlags) -> [String]
```

```objc
- (NSArray<NSString *> *) removeIncompatibleLayerContent:(NSArray<NSString *> *) fontMasterIds options:(GSLayerCompareFlags) options;
```

```python
removeIncompatibleLayerContent_options_(fontMasterIds: list[str], options: GSLayerCompareFlags) -> list[str]
```

## Parameters

- `fontMasterIds` — The layer identifiers to inspect.
- `options` — The aspects of the layers to compare.

## Return Value

The identifiers whose layers were retained.

## See Also

### Layer Compatibility

- [`GSGlyph mastersCompatible`](/Core/GlyphsCore/GSGlyph/mastersCompatible) — Whether every layer group has matching structure for interpolation.
- [`GSGlyph mastersCompatibleForLayers:`](/Core/GlyphsCore/GSGlyph/mastersCompatibleForLayers:) — Whether the layers have matching shapes, anchor names, and path-component hints.
- [`GSGlyph mastersCompatibleForLayerIds:`](/Core/GlyphsCore/GSGlyph/mastersCompatibleForLayerIds:) — Whether the specified layers have matching shapes, anchor names, and path-component hints.
- [`GSGlyph mastersCompatibleForLayerIds:options:`](/Core/GlyphsCore/GSGlyph/mastersCompatibleForLayerIds:options:) — Whether selected aspects of the specified layers have matching structure.
- [`GSGlyph resetMasterCompatibilityCheckStatus`](/Core/GlyphsCore/GSGlyph/resetMasterCompatibilityCheckStatus) — Marks layer compatibility for reevaluation.

