From 1276a490850138721846420c397db314851cd1d5 Mon Sep 17 00:00:00 2001 From: Pietro Monticone <38562595+pitmonticone@users.noreply.github.com> Date: Thu, 20 Apr 2023 08:58:25 +0200 Subject: [PATCH] Fix a few typos in docs and docstrings (#638) * Fix typo in Security.md * Fix typo in tutorial Remove unnecessary close parenthesis ")". * Fix typos in Configuration.jl docstring * Fix typo in Exceptions.jl docstring * Update Generator.jl * Fix typo in Requests.jl docstring * Fix typo in Router.jl docstring * Fix typo in Util.jl docstrings --- Security.md | 4 ++-- .../tutorials/92--Deploying_Genie_Server_Apps_with_Nginx.md | 2 +- src/Configuration.jl | 2 +- src/Exceptions.jl | 4 ++-- src/Generator.jl | 4 ++-- src/Requests.jl | 4 ++-- src/Router.jl | 4 ++-- src/Util.jl | 2 +- 8 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Security.md b/Security.md index 611a08b88..0944ab4b8 100644 --- a/Security.md +++ b/Security.md @@ -51,9 +51,9 @@ involving the following steps: * Confirm the problem and determine the affected versions. * Audit code to find any potential similar problems. * Prepare fixes for all releases still under maintenance. These fixes will be - released as fast as possible and will be available with latest tagged Genie version and annouced on [Genie's twitter](https://twitter.com/GenieMVC) and [Genie's Discord #announcement channel](https://discord.com/invite/9zyZbD6J7H). + released as fast as possible and will be available with latest tagged Genie version and announced on [Genie's twitter](https://twitter.com/GenieMVC) and [Genie's Discord #announcement channel](https://discord.com/invite/9zyZbD6J7H). ## Comments on this Policy If you have suggestions on how this process could be improved please submit a -pull request. \ No newline at end of file +pull request. diff --git a/docs/src/tutorials/92--Deploying_Genie_Server_Apps_with_Nginx.md b/docs/src/tutorials/92--Deploying_Genie_Server_Apps_with_Nginx.md index b162f7cee..f34dd8e73 100644 --- a/docs/src/tutorials/92--Deploying_Genie_Server_Apps_with_Nginx.md +++ b/docs/src/tutorials/92--Deploying_Genie_Server_Apps_with_Nginx.md @@ -5,7 +5,7 @@ This tutorial shows how to host a Julia/Genie app on with Nginx. ## Prerequisites To expose the app over the internet, one needs access to a server. This can be a local machine or a cloud instance such -as AWS EC2 or a Google Cloud Compute Engine for example). +as AWS EC2 or a Google Cloud Compute Engine for example. If using a local server, a static IP is needed to ensure continuous access to the app. Internet service provider generally charge a fee for such extra service. diff --git a/src/Configuration.jl b/src/Configuration.jl index 029ef07ed..6d694754a 100755 --- a/src/Configuration.jl +++ b/src/Configuration.jl @@ -139,7 +139,7 @@ App configuration - sets up the app's defaults. Individual options are overwritt - `path_env::String`: the path to the environment files (default "/env/") - `path_app::String`: the path to the app files (default "app/") - `html_parser_close_tag::String`: default " /". Can be changed to an empty string "" so the single tags would not be closed. -- `webchannels_keepalive_frequency::Int`: default `30000`. Frequency in miliseconds to send keepalive messages to webchannel/websocket to keep the connection alive. Set to `0` to disable keepalive messages. +- `webchannels_keepalive_frequency::Int`: default `30000`. Frequency in milliseconds to send keepalive messages to webchannel/websocket to keep the connection alive. Set to `0` to disable keepalive messages. """ Base.@kwdef mutable struct Settings server_port::Int = 8000 # default port for binding the web server diff --git a/src/Exceptions.jl b/src/Exceptions.jl index 1cdea5e71..8461f20f2 100644 --- a/src/Exceptions.jl +++ b/src/Exceptions.jl @@ -101,7 +101,7 @@ end """ InternalServerException(message::String) -External `InternalServerException` constructor accepting a custome message. +External `InternalServerException` constructor accepting a custom message. """ InternalServerException(message::String) = InternalServerException(message, "", 500) @@ -170,4 +170,4 @@ Custom printing for `FileExistsException` """ Base.show(io::IO, ex::FileExistsException) = print(io, "FileExistsException: $(ex.path)") -end \ No newline at end of file +end diff --git a/src/Generator.jl b/src/Generator.jl index 34cd739da..381282433 100755 --- a/src/Generator.jl +++ b/src/Generator.jl @@ -123,7 +123,7 @@ end """ write_resource_file(resource_path::String, file_name::String, resource_name::String) :: Bool -Generates all resouce files and persists them to disk. +Generates all resource files and persists them to disk. """ function write_resource_file(resource_path::String, file_name::String, resource_name::String, resource_type::Symbol; pluralize::Bool = true) :: Bool resource_name = (pluralize ? (Inflector.to_plural(resource_name)) : resource_name) |> Inflector.from_underscores @@ -413,7 +413,7 @@ function write_app_custom_files(path::String, app_path::String) :: Nothing # This file is autogenerated to run all tests in the context of your Genie app. # It is not necessary to edit this file. # To create tests, simply add `.jl` test files in the `test/` folder. - # All `.jl` files in the `test/` folder will be automaticlaly executed by running `\$ julia --project runtests.jl` + # All `.jl` files in the `test/` folder will be automatically executed by running `\$ julia --project runtests.jl` # If you want to selectively run tests, use `\$ julia --project runtests.jl test_file_1 test_file_2` ENV["GENIE_ENV"] = "test" diff --git a/src/Requests.jl b/src/Requests.jl index e3bdf9f82..34ff7a905 100644 --- a/src/Requests.jl +++ b/src/Requests.jl @@ -136,7 +136,7 @@ end """ getpayload() :: Dict{Symbol,Any} -A dict representing the GET/query variables payload of the request (the part correspoding to `?foo=bar&baz=moo`) +A dict representing the GET/query variables payload of the request (the part corresponding to `?foo=bar&baz=moo`) """ function getpayload() :: Dict{Symbol,Any} haskey(Router.params(), Genie.Router.PARAMS_GET_KEY) ? Router.params(Genie.Router.PARAMS_GET_KEY) : Dict{Symbol,Any}() @@ -307,4 +307,4 @@ function currenturl(req::HTTP.Request = getrequest()) :: String req.target end -end \ No newline at end of file +end diff --git a/src/Router.jl b/src/Router.jl index ef3c49b39..04dbc69fa 100755 --- a/src/Router.jl +++ b/src/Router.jl @@ -1,6 +1,6 @@ """ Parses requests and extracts parameters, setting up the call variables and invoking -the appropiate route handler function. +the appropriate route handler function. """ module Router @@ -341,7 +341,7 @@ end """ -Gets the `Route` correspoding to `routename` +Gets the `Route` corresponding to `routename` """ function get_route(route_name::Symbol; default::Union{Route,Nothing} = Route()) :: Route isroute(route_name) ? diff --git a/src/Util.jl b/src/Util.jl index 85edfca45..21718b01b 100755 --- a/src/Util.jl +++ b/src/Util.jl @@ -59,7 +59,7 @@ const walkdir = walk_dir """ filterwhitespace(s::String, allowed::Vector{Char} = Char[]) :: String -Removes whitespaces from `s`, whith the exception of the characters in `allowed`. +Removes whitespaces from `s`, with the exception of the characters in `allowed`. """ function filterwhitespace(s::S, allowed::Vector{Char} = Char[])::String where {S<:AbstractString} filter(x -> (x in allowed) || ! isspace(x), string(s))