Migrate to isValidRecord in threadgate/util

This commit is contained in:
Eric Bailey
2025-01-02 17:05:55 -06:00
parent 19cb6aa605
commit df51b486f2
+1 -3
View File
@@ -6,9 +6,7 @@ export function threadgateViewToAllowUISetting(
threadgateView: AppBskyFeedDefs.ThreadgateView | undefined,
): ThreadgateAllowUISetting[] {
const threadgate =
threadgateView &&
AppBskyFeedThreadgate.isRecord(threadgateView.record) &&
AppBskyFeedThreadgate.validateRecord(threadgateView.record).success
threadgateView && AppBskyFeedThreadgate.isValidRecord(threadgateView.record)
? threadgateView.record
: undefined
return threadgateRecordToAllowUISetting(threadgate)