Tags: antoinepalazzolo/vapor
Tags
Move the logging of each route's request method and path into a separ… …ate middleware, enabled by default, so that users who don't want it can turn it off. Also fixes a copy-paste error in a fatal error message. (vapor#2521)
Honor Configuration for Optional Date Decoding & Encoding (vapor#2520) * Add failing test for vapor#2518 * Extract Date-Decoding into an extension * Use configuration for decoding of optional Dates (fixes vapor#2518) * Extract Date-encoding into an extension * Use configuration for encoding of optional Dates * Update Formatting in URLEncodedFormDecoder.swift Co-authored-by: Siemen Sikkema <[email protected]> * Update test name Co-authored-by: Tim Condon <[email protected]> Co-authored-by: Andreas Tielmann <[email protected]> Co-authored-by: Siemen Sikkema <[email protected]> Co-authored-by: Tim Condon <[email protected]>
Reuse the application's event loop group and thread pool when loading… … .env files (vapor#2517) * Avoid creating new eventLoopGroup unnecessarily * Align related logs outputs * Add overloads of load functions that accept filio * Add `self` and fix API doc comments * Fix variable names * Avoid creating 2 eventloop groups for each env file * Deprecate functions Co-authored-by: Jari (LotU) <[email protected]>
Provide option to implement `shouldUpgrade` on webSockets (vapor#2487) * Provide option to implement shouldUpgrade on ws * Apply feedback for better readability * Add API docs * Add tests * Fix code style Co-authored-by: Siemen Sikkema <[email protected]> Co-authored-by: Siemen Sikkema <[email protected]>
Make sure paramters passed to dotenv load method are used. (vapor#2514)
Array validation (vapor#2473) * Add missing validation for nested collections (vapor#2238) * Add missing validation of nested arrays * More readable validationResult description * Rename v.addForEach() to v.add(forEach:) * Requested changes * Adjust tests for code changes * Fix intendation * Add test for whole nested array validation message Co-authored-by: Tanner <[email protected]> * fix merge issue * fix tests * test clean, index impl, error string cleanup * fix ordering * Update Tests/VaporTests/ValidationTests.swift Co-authored-by: Siemen Sikkema <[email protected]> * Update Tests/VaporTests/ValidationTests.swift Co-authored-by: Siemen Sikkema <[email protected]> Co-authored-by: Simon Edelmann <[email protected]> Co-authored-by: Siemen Sikkema <[email protected]>
OTP implementation (vapor#2499) * OTP implementations * Added HOTP and TOTP implementations * Added HOTP adn TOTP tests * Cleanup + Cleaned up some of the leftover code. * Import fixed * Fixed an issue with an invalid import of Crypto * Fixed another import * Fixed another import issue in the implementation * Swift 5.2 support * Updated the code to (hopefully) support Swift 5.2 * Consistency * Moved a parameter around for a more consistent structure * Updated OTP API * Made the init public * Removed the static 'initializers' * Updated tests to support new API * Style guide conformance * Added the style guide conformance to function indentation
Add static dotenv loading function that can be used outside of Applic… …ation (vapor#2497) - DotEnv files can be loaded before initializing application - Reduces boilerplate code when you want to bootstrap logging with environment variables loaded from a .env file - Can be loaded in similar fashion as `Application` or provide absolute and relative .env file locations using `DotEnvFile.load(path: ...)` ```swift let env = try Environment.detect() DotEnvFile.load(for: env) LoggingSystem.bootstrap { label in // use environment variables here (before application is initialized) } let app = Application(env) ```
fix relative percent decoding in file middleware (vapor#2500)
Default cookie's SameSite attribute to lax (vapor#2495) * SameSite Attirbute default=lax * Allow nil for sameSite * Update comment Co-authored-by: Jari (LotU) <[email protected]>
PreviousNext