{{ $t('About this instance') }}
- {{ $t("Your local administrator resumed it's policy:") }} + {{ $t("Your local administrator resumed its policy:") }}
- {{ $t('Enjoy discovering Mobilizon!') }} diff --git a/lib/mobilizon/media/media.ex b/lib/mobilizon/media/media.ex index 2062ae074..7f9b6fe8e 100644 --- a/lib/mobilizon/media/media.ex +++ b/lib/mobilizon/media/media.ex @@ -24,7 +24,7 @@ defmodule Mobilizon.Media do def get_picture!(id), do: Repo.get!(Picture, id) @doc """ - Get a picture by it's URL. + Get a picture by its URL. """ @spec get_picture_by_url(String.t()) :: Picture.t() | nil def get_picture_by_url(url) do diff --git a/lib/mobilizon_web/resolvers/event.ex b/lib/mobilizon_web/resolvers/event.ex index e627d0cc4..dac24a98b 100644 --- a/lib/mobilizon_web/resolvers/event.ex +++ b/lib/mobilizon_web/resolvers/event.ex @@ -172,7 +172,7 @@ defmodule MobilizonWeb.Resolvers.Event do {:ok, participant} else {:maximum_attendee_capacity, _} -> - {:error, "The event has already reached it's maximum capacity"} + {:error, "The event has already reached its maximum capacity"} {:has_event, _} -> {:error, "Event with this ID #{inspect(event_id)} doesn't exist"} @@ -329,7 +329,7 @@ defmodule MobilizonWeb.Resolvers.Event do # If we have an attached picture, just transmit it. It will be handled by # Mobilizon.Service.ActivityPub.Utils.make_picture_data/1 - # However, we need to pass it's actor ID + # However, we need to pass its actor ID @spec save_attached_picture(map()) :: {:ok, map()} defp save_attached_picture( %{picture: %{picture: %{file: %Plug.Upload{} = _picture} = all_pic}} = args diff --git a/lib/mobilizon_web/resolvers/user.ex b/lib/mobilizon_web/resolvers/user.ex index af009dcb2..487ab2724 100644 --- a/lib/mobilizon_web/resolvers/user.ex +++ b/lib/mobilizon_web/resolvers/user.ex @@ -14,7 +14,7 @@ defmodule MobilizonWeb.Resolvers.User do require Logger @doc """ - Find an user by it's ID + Find an user by its ID """ def find_user(_parent, %{id: id}, _resolution) do Users.get_user_with_actors(id) @@ -128,7 +128,7 @@ defmodule MobilizonWeb.Resolvers.User do end @doc """ - Validate an user, get it's actor and a token + Validate an user, get its actor and a token """ def validate_user(_parent, %{token: token}, _resolution) do with {:check_confirmation_token, {:ok, %User{} = user}} <- diff --git a/lib/mobilizon_web/schema/actors/group.ex b/lib/mobilizon_web/schema/actors/group.ex index f88192dd1..382df7f1c 100644 --- a/lib/mobilizon_web/schema/actors/group.ex +++ b/lib/mobilizon_web/schema/actors/group.ex @@ -89,7 +89,7 @@ defmodule MobilizonWeb.Schema.Actors.GroupType do resolve(&Group.list_groups/3) end - @desc "Get a group by it's preferred username" + @desc "Get a group by its preferred username" field :group, :group do arg(:preferred_username, non_null(:string)) resolve(&Group.find_group/3) diff --git a/lib/mobilizon_web/schema/actors/person.ex b/lib/mobilizon_web/schema/actors/person.ex index 7052cdd89..bcddea046 100644 --- a/lib/mobilizon_web/schema/actors/person.ex +++ b/lib/mobilizon_web/schema/actors/person.ex @@ -70,13 +70,13 @@ defmodule MobilizonWeb.Schema.Actors.PersonType do resolve(&Person.get_current_person/3) end - @desc "Get a person by it's (federated) username" + @desc "Get a person by its (federated) username" field :fetch_person, :person do arg(:preferred_username, non_null(:string)) resolve(&Person.fetch_person/3) end - @desc "Get a person by it's ID" + @desc "Get a person by its ID" field :person, :person do arg(:id, non_null(:id)) resolve(&Person.get_person/3) diff --git a/lib/service/activity_pub/activity_pub.ex b/lib/service/activity_pub/activity_pub.ex index 181807b82..9b5426328 100644 --- a/lib/service/activity_pub/activity_pub.ex +++ b/lib/service/activity_pub/activity_pub.ex @@ -480,7 +480,7 @@ defmodule Mobilizon.Service.ActivityPub do end @doc """ - Create an actor locally by it's URL (AP ID) + Create an actor locally by its URL (AP ID) """ @spec make_actor_from_url(String.t(), boolean()) :: {:ok, %Actor{}} | {:error, any()} def make_actor_from_url(url, preload \\ false) do @@ -520,7 +520,7 @@ defmodule Mobilizon.Service.ActivityPub do def find_or_make_group_from_nickname(nick), do: find_or_make_actor_from_nickname(nick, :Group) @doc """ - Create an actor inside our database from username, using WebFinger to find out it's AP ID and then fetch it + Create an actor inside our database from username, using WebFinger to find out its AP ID and then fetch it """ @spec make_actor_from_nickname(String.t()) :: {:ok, %Actor{}} | {:error, any()} def make_actor_from_nickname(nickname) do @@ -611,7 +611,7 @@ defmodule Mobilizon.Service.ActivityPub do ) end - # Fetching a remote actor's information through it's AP ID + # Fetching a remote actor's information through its AP ID @spec fetch_and_prepare_actor_from_url(String.t()) :: {:ok, struct()} | {:error, atom()} | any() defp fetch_and_prepare_actor_from_url(url) do Logger.debug("Fetching and preparing actor from url") diff --git a/lib/service/export/feed.ex b/lib/service/export/feed.ex index 77ff71424..ae0f3f2bc 100644 --- a/lib/service/export/feed.ex +++ b/lib/service/export/feed.ex @@ -54,7 +54,7 @@ defmodule Mobilizon.Service.Export.Feed do end end - # Build an atom feed from actor and it's public events + # Build an atom feed from actor and its public events @spec build_actor_feed(Actor.t(), list(), boolean()) :: String.t() defp build_actor_feed(%Actor{} = actor, events, public \\ true) do display_name = Actor.display_name(actor) @@ -159,7 +159,7 @@ defmodule Mobilizon.Service.Export.Feed do |> Enum.map(&Events.get_event_with_preload!/1) end - # Build an atom feed from actor and it's public events + # Build an atom feed from actor and its public events @spec build_user_feed(list(), User.t(), String.t()) :: String.t() defp build_user_feed(events, %User{email: email}, token) do self_url = Endpoint |> Routes.feed_url(:going, token, "atom") |> URI.decode() diff --git a/schema.graphql b/schema.graphql index 9e139a44a..5b70032ef 100644 --- a/schema.graphql +++ b/schema.graphql @@ -1134,10 +1134,10 @@ type RootQueryType { """Get all events""" events(limit: Int = 10, page: Int = 1): [Event] - """Get a person by it's (federated) username""" + """Get a person by its (federated) username""" fetchPerson(preferredUsername: String!): Person - """Get a group by it's preferred username""" + """Get a group by its preferred username""" group(preferredUsername: String!): Group """Get all groups""" @@ -1152,7 +1152,7 @@ type RootQueryType { """Get the current user""" loggedUser: User - """Get a person by it's ID""" + """Get a person by its ID""" person(id: ID!): Person """Get a picture""" diff --git a/test/mobilizon/actors/actors_test.exs b/test/mobilizon/actors/actors_test.exs index 2727f4d17..119149290 100644 --- a/test/mobilizon/actors/actors_test.exs +++ b/test/mobilizon/actors/actors_test.exs @@ -72,7 +72,7 @@ defmodule Mobilizon.ActorsTest do assert actor_id == Users.get_actor_for_user(user).id end - test "get_actor_with_preload/1 returns the actor with it's organized events", %{ + test "get_actor_with_preload/1 returns the actor with its organized events", %{ actor: actor } do assert Actors.get_actor_with_preload(actor.id).organized_events == [] @@ -113,7 +113,7 @@ defmodule Mobilizon.ActorsTest do end end - test "get_local_actor_by_name_with_preload!/1 returns the local actor with it's organized events", + test "get_local_actor_by_name_with_preload!/1 returns the local actor with its organized events", %{ actor: actor } do @@ -130,7 +130,7 @@ defmodule Mobilizon.ActorsTest do assert event_found_id == event.id end - test "get_actor_by_name_with_preload!/1 returns the local actor with it's organized events", + test "get_actor_by_name_with_preload!/1 returns the local actor with its organized events", %{ actor: actor } do @@ -147,7 +147,7 @@ defmodule Mobilizon.ActorsTest do assert event_found_id == event.id end - test "get_actor_by_name_with_preload!/1 returns the remote actor with it's organized events" do + test "get_actor_by_name_with_preload!/1 returns the remote actor with its organized events" do use_cassette "actors/remote_actor_mastodon_tcit" do with {:ok, %Actor{} = actor} <- ActivityPub.get_or_fetch_by_url(@remote_account_url) do assert Actors.get_actor_by_name_with_preload( @@ -230,7 +230,7 @@ defmodule Mobilizon.ActorsTest do refute actor.suspended end - test "update_actor/2 with valid data updates the actor and it's media files", %{ + test "update_actor/2 with valid data updates the actor and its media files", %{ actor: %Actor{avatar: %{url: avatar_url}, banner: %{url: banner_url}} = actor } do %URI{path: "/media/" <> avatar_path} = URI.parse(avatar_url) diff --git a/test/mobilizon/service/activity_pub/activity_pub_test.exs b/test/mobilizon/service/activity_pub/activity_pub_test.exs index 59583ecf4..be66f851e 100644 --- a/test/mobilizon/service/activity_pub/activity_pub_test.exs +++ b/test/mobilizon/service/activity_pub/activity_pub_test.exs @@ -42,7 +42,7 @@ defmodule Mobilizon.Service.ActivityPub.ActivityPubTest do end end - describe "fetching actor from it's url" do + describe "fetching actor from its url" do test "returns an actor from nickname" do use_cassette "activity_pub/fetch_tcit@framapiaf.org" do assert {:ok, %Actor{preferred_username: "tcit", domain: "framapiaf.org"} = actor} = diff --git a/test/mobilizon/users/users_test.exs b/test/mobilizon/users/users_test.exs index bb43805ab..8e901e456 100644 --- a/test/mobilizon/users/users_test.exs +++ b/test/mobilizon/users/users_test.exs @@ -74,7 +74,7 @@ defmodule Mobilizon.UsersTest do Users.authenticate(%{user: user, password: "bad password"}) end - test "get_user_by_email/1 finds an user by it's email" do + test "get_user_by_email/1 finds an user by its email" do {:ok, %User{email: email} = user} = Users.register(%{email: @email, password: @password}) assert email == @email @@ -83,7 +83,7 @@ defmodule Mobilizon.UsersTest do assert {:error, :user_not_found} = Users.get_user_by_email("no email") end - test "get_user_by_email/1 finds an activated user by it's email" do + test "get_user_by_email/1 finds an activated user by its email" do {:ok, %User{} = user} = Users.register(%{email: @email, password: @password}) {:ok, %User{id: id}} = Users.get_user_by_email(@email, false) diff --git a/test/mobilizon_web/resolvers/group_resolver_test.exs b/test/mobilizon_web/resolvers/group_resolver_test.exs index 784aa0de0..e7bff0607 100644 --- a/test/mobilizon_web/resolvers/group_resolver_test.exs +++ b/test/mobilizon_web/resolvers/group_resolver_test.exs @@ -106,7 +106,7 @@ defmodule MobilizonWeb.Resolvers.GroupResolverTest do group.preferred_username end - test "find_group/3 returns a group by it's username", context do + test "find_group/3 returns a group by its username", context do group = insert(:group) query = """ diff --git a/test/mobilizon_web/resolvers/participant_resolver_test.exs b/test/mobilizon_web/resolvers/participant_resolver_test.exs index bd195d47c..75c6e2d8c 100644 --- a/test/mobilizon_web/resolvers/participant_resolver_test.exs +++ b/test/mobilizon_web/resolvers/participant_resolver_test.exs @@ -141,7 +141,7 @@ defmodule MobilizonWeb.Resolvers.ParticipantResolverTest do |> post("/api", AbsintheHelpers.mutation_skeleton(mutation)) assert hd(json_response(res, 200)["errors"])["message"] == - "The event has already reached it's maximum capacity" + "The event has already reached its maximum capacity" end test "actor_join_event/3 should check the actor is owned by the user", %{ diff --git a/test/mobilizon_web/resolvers/person_resolver_test.exs b/test/mobilizon_web/resolvers/person_resolver_test.exs index 49d027aa9..b8cd88d73 100644 --- a/test/mobilizon_web/resolvers/person_resolver_test.exs +++ b/test/mobilizon_web/resolvers/person_resolver_test.exs @@ -7,7 +7,7 @@ defmodule MobilizonWeb.Resolvers.PersonResolverTest do @non_existent_username "nonexistent" describe "Person Resolver" do - test "get_person/3 returns a person by it's username", context do + test "get_person/3 returns a person by its username", context do user = insert(:user) actor = insert(:actor, user: user) @@ -44,7 +44,7 @@ defmodule MobilizonWeb.Resolvers.PersonResolverTest do "Person with ID 6895567 not found" end - test "find_person/3 returns a person by it's username", context do + test "find_person/3 returns a person by its username", context do user = insert(:user) actor = insert(:actor, user: user) diff --git a/test/mobilizon_web/resolvers/user_resolver_test.exs b/test/mobilizon_web/resolvers/user_resolver_test.exs index 701cb44f8..c8418df0b 100644 --- a/test/mobilizon_web/resolvers/user_resolver_test.exs +++ b/test/mobilizon_web/resolvers/user_resolver_test.exs @@ -18,7 +18,7 @@ defmodule MobilizonWeb.Resolvers.UserResolverTest do @valid_single_actor_params %{preferred_username: "test2", keys: "yolo"} describe "Resolver: Get an user" do - test "find_user/3 returns an user by it's id", context do + test "find_user/3 returns an user by its id", context do user = insert(:user) query = """