Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Commit 189b660

Browse files
committed
Merge branch 'hotfix/39'
Close #39
2 parents a11976f + 6e5a8af commit 189b660

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ Versions 0.3.0 and prior were released as "weierophinney/problem-details".
2424

2525
### Fixed
2626

27-
- Nothing.
27+
- [#39](https://github.com/zendframework/zend-problem-details/pull/39)
28+
adds the `public` visibility modifier to all constants.
2829

2930
## 1.0.0 - 2018-03-15
3031

src/ProblemDetailsResponseFactory.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,23 +59,23 @@ class ProblemDetailsResponseFactory
5959
/**
6060
* @var string Content-Type header for JSON responses
6161
*/
62-
const CONTENT_TYPE_JSON = 'application/problem+json';
62+
public const CONTENT_TYPE_JSON = 'application/problem+json';
6363

6464
/**
6565
* @var string Content-Type header for XML responses
6666
*/
67-
const CONTENT_TYPE_XML = 'application/problem+xml';
67+
public const CONTENT_TYPE_XML = 'application/problem+xml';
6868

6969
/**
7070
* @var string Default detail message to use for exceptions when the
7171
* $exceptionDetailsInResponse flag is false.
7272
*/
73-
const DEFAULT_DETAIL_MESSAGE = 'An unknown error occurred.';
73+
public const DEFAULT_DETAIL_MESSAGE = 'An unknown error occurred.';
7474

7575
/**
7676
* @var string[] Default problem detail titles based on status code
7777
*/
78-
const DEFAULT_TITLE_MAP = [
78+
public const DEFAULT_TITLE_MAP = [
7979
// 4×× Client Error
8080
StatusCode::STATUS_BAD_REQUEST => 'Bad Request',
8181
StatusCode::STATUS_UNAUTHORIZED => 'Unauthorized',
@@ -129,7 +129,7 @@ class ProblemDetailsResponseFactory
129129
*
130130
* @var bool
131131
*/
132-
const EXCLUDE_THROWABLE_DETAILS = false;
132+
public const EXCLUDE_THROWABLE_DETAILS = false;
133133

134134
/**
135135
* Constant value to indicate throwable details (backtrace, previous
@@ -138,12 +138,12 @@ class ProblemDetailsResponseFactory
138138
*
139139
* @var bool
140140
*/
141-
const INCLUDE_THROWABLE_DETAILS = true;
141+
public const INCLUDE_THROWABLE_DETAILS = true;
142142

143143
/**
144144
* @var string[] Accept header types to match.
145145
*/
146-
const NEGOTIATION_PRIORITIES = [
146+
public const NEGOTIATION_PRIORITIES = [
147147
'application/json',
148148
'application/*+json',
149149
'application/xml',

0 commit comments

Comments
 (0)