Skip to content

Commit 7869da9

Browse files
Code for 1.2.1 (#38)
* Updated Readme * Added location property to box.json to point to MindscapeHQ repo. * Additional minor changes to stacktrace handling. Request URL now combines script name and path info from CGI.
1 parent 77107ba commit 7869da9

File tree

5 files changed

+16
-24
lines changed

5 files changed

+16
-24
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ raygun4cfml
33

44
Raygun.io API client for CFML.
55

6-
Current Version: 1.2.0 (Jun 8 2021)
6+
Current Version: 1.2.1 (Jun 16 2021)
77

88
Dependencies:
99

box.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name":"raygun4cfml",
3-
"version":"1.2.0",
3+
"version":"1.2.1",
4+
"location":"MindscapeHQ/raygun4cfml#1.2.1",
45
"author":"Kai Koenig <kai@ventego-creative.co.nz>",
56
"homepage":"https://github.com/MindscapeHQ/raygun4cfml/",
67
"documentation":"https://github.com/MindscapeHQ/raygun4cfml/blob/master/README.md",

changelog.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
History
22
=======
33

4+
1.2.1 (Jun 16 2021)
5+
6+
- Minor changes to stacktrace handling
7+
- Additional of Path Info to Request URL data
8+
49
1.2.0 (Jun 8 2021)
510

611
- Support for version (#34)

src/nz/co/ventego-creative/raygun4cfml/RaygunExceptionMessage.cfc

Lines changed: 7 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -75,18 +75,11 @@ limitations under the License.
7575
tagContextData[j]["lineNumber"] = trim( arguments.issueDataStruct.tagcontext[j]["line"] );
7676
}
7777

78+
returnContent["data"] = {"JavaStrackTrace" = stackTraceData};
7879
returnContent["stackTrace"] = tagContextData;
79-
80-
if (isLucee || isACF2021) {
81-
returnContent["stackTrace"] = stackTraceData;
82-
} else {
83-
returnContent["data"] = {"JavaStrackTrace" = stackTraceData};
84-
returnContent["stackTrace"] = tagContextData;
85-
}
8680

8781
// if we deal with an error struct, there'll be a root cause
88-
if (StructKeyExists(arguments.issueDataStruct,"RootCause"))
89-
{
82+
if (StructKeyExists(arguments.issueDataStruct,"RootCause")) {
9083
if (StructKeyExists(arguments.issueDataStruct["RootCause"],"Type") and arguments.issueDataStruct["RootCause"]["Type"] eq "expression")
9184
{
9285
returnContent["data"]["type"] = arguments.issueDataStruct["RootCause"]["Type"];
@@ -95,21 +88,14 @@ limitations under the License.
9588
{
9689
returnContent["message"] = arguments.issueDataStruct["RootCause"]["Message"];
9790
}
98-
returnContent["catchingMethod"] = "error struct";
99-
}
100-
// otherwise there's no root cause and the specific data has to be grabbed from somewhere else
101-
else
102-
{
103-
if (!isLucee || isACF2021) {
91+
returnContent["catchingMethod"] = "Error struct";
92+
} else {
93+
// otherwise there's no root cause and the specific data has to be grabbed from somewhere else
94+
if (!isLucee || isACF2021) {
10495
returnContent["data"]["type"] = arguments.issueDataStruct.type;
10596
}
10697
returnContent["message"] = arguments.issueDataStruct.message;
107-
returnContent["catchingMethod"] = "cfcatch struct";
108-
}
109-
110-
// Look for CFML code snippet in TagContext
111-
if (StructKeyExists(arguments.issueDataStruct,"TagContext") && isArray(arguments.issueDataStruct["TagContext"]) && structKeyExists(arguments.issueDataStruct["TagContext"][1],"codePrintPlain")) {
112-
returnContent["data"]["code"] = arguments.issueDataStruct["TagContext"][1]["codePrintPlain"];
98+
returnContent["catchingMethod"] = "CFCatch struct";
11399
}
114100

115101
returnContent["className"] = trim( arguments.issueDataStruct.type );

src/nz/co/ventego-creative/raygun4cfml/RaygunRequestMessage.cfc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ limitations under the License.
3333
var rawDataMaxLength = 4096;
3434

3535
returnContent["hostName"] = CGI.HTTP_HOST;
36-
returnContent["url"] = CGI.SCRIPT_NAME;
36+
returnContent["url"] = CGI.SCRIPT_NAME & CGI.PATH_INFO
3737
returnContent["httpMethod"] = CGI.REQUEST_METHOD;
3838
returnContent["iPAddress"] = CGI.REMOTE_ADDR;
3939
returnContent["queryString"] = CGI.QUERY_STRING;

0 commit comments

Comments
 (0)