30 lines
752 B
Swift
30 lines
752 B
Swift
//
|
|
// HashtagSearchResultsViewController.swift
|
|
// Tusker
|
|
//
|
|
// Created by Shadowfacts on 1/24/21.
|
|
// Copyright © 2021 Shadowfacts. All rights reserved.
|
|
//
|
|
|
|
import UIKit
|
|
|
|
class HashtagSearchResultsViewController: SearchResultsViewController {
|
|
|
|
init(mastodonController: MastodonController) {
|
|
super.init(mastodonController: mastodonController, resultTypes: [.hashtags])
|
|
}
|
|
|
|
required init?(coder: NSCoder) {
|
|
fatalError("init(coder:) has not been implemented")
|
|
}
|
|
|
|
override func performSearch(query: String?) {
|
|
if let query = query, !query.starts(with: "#") {
|
|
super.performSearch(query: "#\(query)")
|
|
} else {
|
|
super.performSearch(query: query)
|
|
}
|
|
}
|
|
|
|
}
|