Skip to content

Commit

Permalink
Extension String.getLinks() should only be available on apple platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
juliangerhards committed Jan 4, 2022
1 parent dc45f31 commit 5acb6e4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Sources/SwiftPlus/Extensions/String.swift
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ public extension String {
}
#endif

#if os(iOS)
/// Searches for Links in String
/// - Returns: Dictionary of LinkString: NSRange
func getLinks() -> [String: NSRange]{
Expand All @@ -60,6 +61,7 @@ public extension String {
return [:]
}
}
#endif

/// Searches for Hashtags in String
/// - Returns: Dictionary of HashtagString: NSRange
Expand Down

0 comments on commit 5acb6e4

Please sign in to comment.