mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-25 09:03:12 +03:00
Remove usage of useSiteUrl
from Activities component
refs https://linear.app/tryghost/issue/AP-469 This takes advantage of the new criteria in the API so that we don't have to use the problematic useSiteUrl.
This commit is contained in:
parent
5bdfac4e1f
commit
2fb4d83b5a
@ -10,7 +10,7 @@ import FollowButton from './global/FollowButton';
|
||||
import MainNavigation from './navigation/MainNavigation';
|
||||
|
||||
import getUsername from '../utils/get-username';
|
||||
import {useActivitiesForUser, useSiteUrl} from '../hooks/useActivityPubQueries';
|
||||
import {useActivitiesForUser} from '../hooks/useActivityPubQueries';
|
||||
import {useFollowersForUser} from '../MainContent';
|
||||
|
||||
interface ActivitiesProps {}
|
||||
@ -86,7 +86,6 @@ const getActivityBadge = (activity: Activity): AvatarBadge => {
|
||||
|
||||
const Activities: React.FC<ActivitiesProps> = ({}) => {
|
||||
const user = 'index';
|
||||
const siteUrl = useSiteUrl();
|
||||
|
||||
const {
|
||||
data,
|
||||
@ -98,7 +97,7 @@ const Activities: React.FC<ActivitiesProps> = ({}) => {
|
||||
includeOwn: true,
|
||||
includeReplies: true,
|
||||
filter: {
|
||||
type: ['Follow', 'Like', `Create:Note:isReplyToOwn,${new URL(siteUrl).hostname}`]
|
||||
type: ['Follow', 'Like', `Create:Note:isReplyToOwn`]
|
||||
}
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user