Skip to content

Commit 0571db3

Browse files
committed
Merge branch 'development'
2 parents 1dfd73e + 33eab16 commit 0571db3

File tree

4 files changed

+21
-1
lines changed

4 files changed

+21
-1
lines changed

box.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name":"ColdBox Security",
3-
"version":"3.2.0",
3+
"version":"3.3.0",
44
"location":"https://downloads.ortussolutions.com/ortussolutions/coldbox-modules/cbsecurity/@build.version@/[email protected]@.zip",
55
"author":"Ortus Solutions.com <[email protected]>",
66
"slug":"cbsecurity",

changelog.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99

1010
## [Unreleased]
1111

12+
## [3.3.0] => 2023-MAR-31
13+
14+
### Added
15+
16+
- Added `guest()` method to CBSecurity model and `Authorizable` delegate
17+
1218
## [3.2.0] => 2023-MAR-29
1319

1420
### Added

models/CBSecurity.cfc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,13 @@ component threadsafe singleton accessors="true" {
250250
return getAuthService().isLoggedIn();
251251
}
252252

253+
/**
254+
* Verifies if a user is NOT logged in
255+
*/
256+
boolean function guest(){
257+
return !getAuthService().isLoggedIn();
258+
}
259+
253260
/**
254261
* Login Facade
255262
*

models/delegates/Authorizable.cfc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,13 @@ component {
5252
return variables.cbSecurity.isLoggedIn();
5353
}
5454

55+
/**
56+
* Verifies if a user is NOT logged in
57+
*/
58+
boolean function guest(){
59+
return variables.cbSecurity.guest();
60+
}
61+
5562
/***************************************************************/
5663
/* Verification Methods
5764
/***************************************************************/

0 commit comments

Comments
 (0)