Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
preciz committed Sep 7, 2024
1 parent 685dc86 commit cd45e77
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion lib/phoenix/pubsub/pg2.ex
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ defmodule Phoenix.PubSub.PG2 do
:"#{adapter_name}_#{number}"
end

# Use `adapter_name` for the first in the pool for backwards compatability
# Use `adapter_name` for the first in the pool for backwards compatibility
# with v2.0 when the pool_size is 1.
groups = [adapter_name | groups]

Expand Down
6 changes: 3 additions & 3 deletions lib/phoenix/tracker.ex
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ defmodule Phoenix.Tracker do
* `server_name` - The registered name of the tracker server
* `topic` - The `Phoenix.PubSub` topic
Returns a lists of presences in key/metadata tuple pairs.
Returns a list of presences in key/metadata tuple pairs.
## Examples
Expand All @@ -217,12 +217,12 @@ defmodule Phoenix.Tracker do
* `topic` - The `Phoenix.PubSub` topic
* `key` - The key of the presence
Returns a lists of presence metadata.
Returns a list of presence metadata.
## Examples
iex> Phoenix.Tracker.get_by_key(MyTracker, "lobby", "user1")
[{#PID<0.88.0>, %{name: "User 1"}, {#PID<0.89.0>, %{name: "User 1"}]
[{#PID<0.88.0>, %{name: "User 1"}}, {#PID<0.89.0>, %{name: "User 1"}}]
"""
@spec get_by_key(atom, topic, term) :: [{pid, map}]
def get_by_key(tracker_name, topic, key) do
Expand Down
4 changes: 2 additions & 2 deletions lib/phoenix/tracker/delta_generation.ex
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ defmodule Phoenix.Tracker.DeltaGeneration do
"""
@spec extract(State.t, [State.delta], State.name, State.context) :: State.delta | State.t
def extract(%State{mode: :normal} = state, generations, remote_ref, remote_context) do
case delta_fullfilling_clock(generations, remote_context) do
case delta_fulfilling_clock(generations, remote_context) do
{delta, index} ->
if index, do: Logger.debug "#{inspect state.replica}: sending delta generation #{index + 1}"
State.extract(delta, remote_ref, remote_context)
Expand Down Expand Up @@ -54,7 +54,7 @@ defmodule Phoenix.Tracker.DeltaGeneration do
end)
end

defp delta_fullfilling_clock(generations, remote_context) do
defp delta_fulfilling_clock(generations, remote_context) do
generations
|> Enum.with_index()
|> Enum.find(fn {%State{range: {local_start, local_end}}, _} ->
Expand Down
2 changes: 1 addition & 1 deletion test/phoenix/tracker/shard_replication_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ defmodule Phoenix.Tracker.ShardReplicationTest do
refute {@node1, node1_node} in get_values(@node2, node2_shard)
end

# TODO split into multiple testscases
# TODO split into multiple test cases
test "tempdowns with nodeups of new vsn, and permdowns",
%{shard: shard, topic: topic, tracker: tracker} do

Expand Down

0 comments on commit cd45e77

Please sign in to comment.