- Added UUID support to Leaf Auth
- Added support for custom id keys in Leaf Auth
- Fixed Request::getUrl
- Fixed issue #53
- Fixed Database
- Removed Leaf blade component
- Fixed PHP 7.3 unsupported types
- Fixed server base path on router
- Fixed bare UI config method
- Fixed faker namespace
- Removed BETA flag from Leaf password helper
- Removed Leaf blade component
- Leaf debug now controls error reporting (you don't want nasty errors showing in production)
- Added
Request::try
- Added
app.down
config - Added Leaf app instance on
Config
- Added grouped namespaces to router
- Added single route namespaces
- Added named routes to router
- Added router
push
for switching between pages - Added more customizations on
Leaf\Database
- Added simple flash messaging with
Leaf\Flash
- Added
flash
method to session - Added HTTP caching on
Leaf\Http\Headers
- Fixed inverted condition for showing default development/production error pages.
- Fixed router hooks
- Added proper types on
App
andRouter
- Added proper controller and missing method warnings
- Fixed incorrect method labeling
- Fixed HTTP caching issues
- Fixed app logger and app log writer
- Fixed app break after non-existent middlware call
- Switched debugging controls from
mode
todebug
- Default 404 page now automatically loaded
- Router middleware
App
instance now automatically loaded - Added null response for unset session variables
- Leaf error handler now loads on
App
init - Default error 500 handler now automatically loaded
- Updated leaf container
- Removed unnecessary code from
App
- Removed app name
- Removed
view
method on app and router - Removed previous hook support on app
- Removed unused router config
- Removed Leaf environment class
- Removed unused default middleware
Leaf\Blade
no longer comes with Leaf by default.- Removed
status
andcontentType
on Leaf\App
- Added
app.down
config - Added Leaf app instance on
Config
- Added grouped namespaces to router
- Added named routes to router
- Added router group prefixes
- Added router
push
for switching between pages - Added more customizations on
Leaf\Database
- Added simple flash messaging with
Leaf\Flash
- Added
flash
method to session - Added HTTP caching on
Leaf\Http\Headers
- Fixed router hooks
- Added proper types on
App
andRouter
- Added proper controller and missing method warnings
- Fixed incorrect method labeling
- Fixed HTTP caching issues
- Fixed app logger and app log writer
- Fixed app break after non-existent middlware call
- Default 404 page now automatically loaded
- Router middleware
App
instance now automatically loaded - Added null response for unset session variables
- Leaf error handler now loads on
App
init - Default error 500 handler now automatically loaded
- Updated leaf container
- Removed unnecessary code from
App
- Removed app name
- Removed
view
method on app and router - Removed previous hook support on app
- Removed unused router config
- Removed Leaf environment class
- Removed unused default middleware
Leaf\Blade
no longer comes with Leaf by default.- Removed
status
andcontentType
on Leaf\App
- Added
Leaf\Config
for easier configuration - Added new leaf config options
- Added
Leaf\View
- Added support for multiple template engines concurrently
- Added BareUI templating engine
- Internal code improvements on App
- No renames, restructures, ...
- No removals
- Updated
Leaf\Db
andLeaf\Auth
to throw dev errors to Leaf's error handler for better error reporting
- Organized methods in
Leaf\FS
- Made
Leaf\Http\Response
static - Made
Leaf\Http\Request
static
- No removals
This version of Leaf continues the goal of making Leaf features more flexible and increasing usability.
-
Added option to turn off experimental method warnings
-
Added
Form::rule
which allows you to create your own rules for form validation.
Form::rule("max", function($field, $value, $params) {
if (strlen($value) > $params) {
Form::addError($field, "$field can't be more than $params characters");
return false;
}
});
- Added internal
Leaf\Form
feature which allows you to pass parameters to validation rules.
$validation = Form::validate([
// To pass a param to a rule, just use :
"username" => "max:3",
]);
- Added
Form::addError
which allows you to add errors to be returned inForm::errors()
Form::addError($field, "$field can't be more than $params characters");
- Added max and min rules by default
$validation = Form::validate([
"username" => "max:1",
"password" => "min:81",
]);
- Guards can be used even in API mode. This will alert you if you're not eligible to view a particular page.
-
Updated dependencies with security patches
-
Fixed multiple validation break from v2.4.2 beta.
- Made
Leaf\Form
methods static. They can now be called from anywhere within your Leaf app.
- No removals
This release mainly focuses on security patches for all Leaf based libraries. It contains updated dependencies and internal code patches to make your apps even more secure.
- No additions
- Updated dependencies with security patches
- Made
Leaf\Auth
methods static. They can now be called from anywhere within your Leaf app.
- No removals
v2.4.1 continues the usability reforms from the previous versions. It also contains fixes for all bugs discovered in previous versions as well as new features.
Please update from v2.4.0 to v2.4.1 to fix any issues you encountered with the system. Any inconveniences are deeply regretted🙏.
- Added support for session based authenticatication instead of just JWT
- Added
Route::view
- Fixed all known bugs from previous versions
- Separated Router module from app module
- Made all
Leaf\Http\Session
methods static
- Removed app down feature
Please update from v2.4.0 to v2.4.1 to fix any issues you encountered with this version. Any inconveniences are deeply regretted🙏. This release has officially been deleted.
Christmas tree follows up on the previous beta release, fixes up all bugs found during the beta testing phase and packs in newer extensions that make Leaf even more usable.
- Added base factory class for Leaf MVC, Leaf API and Skeleton
- Added new auth setting options
- Fixed
Leaf\Db
callstack not clearing - Fixed
Auth::update
db errors - Fixed
Auth::update
including current user in uniques check - Fixed password verify method params
- Switched default password encryption to
PASSWORD_DEFAULT
(bcrypt by default) - Auth now relies on Leaf password helper for everything password related
- Standardized all
where
type methods onLeaf\Db
- Seperated password encoding and password verifying settings in
Leaf\Auth
- Switched password helper methods to camelCase
- Switched password
salt
withspice
to add additional security to passwords
- Removed unnecessary methods from password helper
Unlike previous versions, this version of Leaf is focusing on improving the use of existing features, rather than just pumping new magic into Leaf. It has a lot of bug fixes, standardization of method names and overall upgrades.
- Added
App::evadeCors
- Added
App::routes
to preview all routes - Added
Db::first()
- Leaf DB can now detect query type even when
query
- Added
orWhere
,whereLike
,orWhereLike
like
,orLike
,orderBy
,all
limit
and LIKE helpers to Leaf Db - Added new format to
Date::now
- Added
Auth::update
- Added custom token lifetime support on
Auth
- Fixed login bug with
Auth::currentUser
- Fixed Leaf DB same value bug
- Minor fixes on
Auth::login
andAuth::register
- Switched methods to camel case
- Renamed
Auth::useToken
toAuth::id
- Renamed
Auth::currentUser
toAuth::user
- Made
Helpers\JWT
andHelpers\Authentication
methods static
- Removed
Form::isEmpty
andForm::isNull
- Removed deprecated methods from
Response
- Removed deprecated methods from
Date
- Added Leaf\Auth::useToken
- Added Leaf\FS::upload_file
- Added manual init to Leaf\Session
- Added option for status code messages
- Added callable utils
- Added session encoding/decoding
- Leaf\Http\Request now catches files passed into request
- Added Leaf\Http\Request::typeIs
- Leaf\Http\Request::get can now return multiple request data at once
- Added Leaf\Http\Request::files
- New Leaf\Http\Headers package
- More untracked additions
- fixed Leaf\Http\Headers
- Fixed response http status codes bug
- Fixed header integration with response
- Fixed header reliance on Set
- Fixed throwErr code error
- Fixed Leaf\Session package
- Fixed response redirect
- Fixed Leaf\Http\Request::body bugs
- Sessions return false instead of throwing errors (Fix for web apps)
- FS returns false instead of throwing errors
- Fixed up Leaf\Http\Request::params
- Fixed up Leaf\Http\Request::hasHeader
- Fixed up header related methods on Leaf\Http\Request
- Fixed bugs on Leaf\Environment
- More untracked fixes
- Switched Leaf\Session to native PHP sessions
- Switched session package in Leaf\App
- Changed controller file uploads to Leaf\FS
- Leaf\Date methods can now be called static-ly
- Switched Leaf\Date methods to camel case, but- with backward compatability for snake_case
- Made all Leaf\FS methods static
- Removed old session code
- Removed setEncryptedCookie and getEncryptedCookie- on Leaf\App
- Slashed unnecessary code from Leaf\Http\Request
- Slashed unnecessary code from Leaf\Http\Session
- Slashed unnecessary code from Leaf\Http\Cookie
- Slashed unnecessary code from Leaf\Http\Response
- Removed all method type tests from Leaf\Http\Request
- Added
Leaf\Auth::currentUser
- Added new cookies package relying on PHP's setcookie
- fixed hidden fields on Leaf\Auth::login
- Fixed multiple-request type data on get and body at Leaf\Http\Request
- Switched cookies package in Leaf\Http\Response
- Switched cookies package in Leaf\App
- Removed old cookies package and all it's methods
- Removed setEncryptedCookie and getEncryptedCookie on Leaf\App
- Slashed unnecessary code from Leaf\Http\Request
- Added
Leaf\Auth::auto_connect
- Added default bypass for CORS errors
- Added
Mysqli::auto_connect
- Added optional
db_type
option toLeaf\Db\PDO
connection - Added
PDO::auto_connect
- Added deprecation warning for
Leaf\Db\PDO
- Removed Leaf\Wynter
- Added Route::resource
- Added Session::retrieve
- Seperated Leaf Veins from Leaf Package
- Renamed Session::getBody to Session::body
- Removed Leaf\View
- Added Leaf Mail
- Added Date::days_ago
- Added Date::months_ago
- Added Date::years_ago
- Added Date::day
- Added Date::month
- Added Date::year
- Added Auth::setSecretKey
- Added Auth::getSecretKey
- Added Auth::validate
- Added Leaf JS Scripts [BETA]
- Added Leaf Envryption Helper [BETA]
- Added Leaf Password Helper [BETA]
- Added secret key for token encryption in Leaf Authentication
- Fixed Request::params
- Fixed Request::getBody
- Fixed Request Method Tests
- Fixes to Auth::validateToken
- Fixed bugs with Leaf DB packages
- Fixed bugs on Auth::login and register
- Fixed base64 security issues on Leaf Token [BETA]
- Fixes on Form::isEmpty and isNull
- Renamed Request
getBody
tobody
- Switched all
Date
methods tosnake_case
- Switched
FS
methods tosnake_case
- Shortened
Date
method names (Find out more in the docs) - Made Leaf Authentication a helper (Leaf\Helper\Authentication)
- Removed Response::count
- Removed Response::getIterator
- Removed Response header offeset methods
- Added DB->choose
- Added DB->add
- Added Auth->login
- Added Auth->register
- Added Session->unset
- Added custom constructor to response
- Added Response->messages(Http codes)
- Added Response->setStatus/getStatus/status
- Added Response->setHeader/getHeader/header
- Added Response->setCookie/deleteCookie
- Added Response->redirect
- Added Request type checks
- Added Request->cookies
- Added Request->headers
- Added Response Helpers
- Added Leaf\Headers
- Added Leaf\Cookies
- Added ContentTypes Middleware
- Added Flash messaging Middleware
- Added PrettyExceptions Middleware
- Added Logwriter and Log
- Added Leaf View
- Merged the Leaf Veins Templating engine and Leaf Core
- Added Support for blade templating with Leaf Blade
- Added support for more request types on Leaf::Request
- Added Form::validateField
- Provided security against XSS
- Added Form::submit
- Fixed SESSION->id
- Fixed headers bug with Response->respondWithCode
- Fixed headers bug with Response->throwErr
- Changed Leaf\Core namespace to Leaf
- Changed Session->remove to Session->unset
- Removed Auth->basicLogin
- Removed Auth->emailLogin
- Removed Auth->basicRegister
- Added FS->deleteFolder
- Added FS->deleteFile
- Added Form->validate😅
- Added Form->validate and return errors to base controllers
- Added Leaf\Core\Str: equivalent of Illuminate\Support\Str with added methods
- Added Leaf Mysqli🤔
- Added Leaf PDO🤔
- Added Leaf\Core\Auth: simple login and signup
- Fixed FS->deleteFile
- Fixed FS->listDir
- Fixed Leaf DB
- Fixed init bug with session
- Renamed Veins->renderTemplate to render
- Rename veins->assign to set()
- Renamed mkdir to createFolder
- Renamed mkdirInBase to createFolderInBase
- Renamed renameDir to renameFolder
- Changed vein file extension from .vein to .vein.php
- Split Leaf\Config\Db between Leaf\Core\Db\Mysqli and Leaf\Core\Db\PDO
- Changed
renderHtml
torenderPage
- Changed all
getParam
s toget
Nothing was removed
- Added FileSystem module
- Added
mysqliQuery
method toleaf\config\db
- Added a bunch of handy session methods
- Added leaf token
- Added leaf form
- Fixed a few problems with
leaf\config\db
; - Fixed tiny bug with
response->throwErr
- Changed
leaf\config\db
: connection variables and connection type are set on db init.$db = new db($host, $user, $password, $dbname, "PDO")
- Renamed renderHtmlPage to renderHtml
- Leaf\Config\DB has been depricated for now
- Added base Leaf Controller
Leaf\Core\Controller
- Added base controller for APIs:
Leaf\Core\ApiController
- Added base Leaf Model
Leaf\Core\Model
- Added support for full MVC app
- Added Leaf Veins in default Leaf package
- Added Error Handling for development and production
- Added a base database layer connected with custom environment variables
- Fixed bug with
Response::renderHtmlPage()
- Fixed the HTTP code rendering in the browser from
Response::respondWithCode
- Changed
Validation
toForm
- Removed Leaf
Exceptions
- Removed Middleware interfaces