Skip to content

Commit

Permalink
support under php 7.4
Browse files Browse the repository at this point in the history
  • Loading branch information
PyaeSoneAungRgn committed Sep 4, 2022
1 parent 6ec7aac commit 2e0e0a2
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
24 changes: 12 additions & 12 deletions src/Support/LaravelMyanmarTools/Nrc.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,24 @@
*/
class Nrc
{
protected string $nrc;
protected $nrc;

protected const EN_CHARS = ['KA', 'KH', 'GA', 'GH', 'NG', 'CA', 'CH', 'JA', 'JH', 'NY', 'DD', 'NN', 'TA', 'TH', 'DA', 'DH', 'NA', 'PA', 'PH', 'BA', 'BH', 'MA', 'YA', 'RA', 'LA', 'WA', 'SA', 'HA', 'LL', 'AH', 'OU', 'AE'];
protected const MM_CHARS = ['က', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''];
const EN_CHARS = ['KA', 'KH', 'GA', 'GH', 'NG', 'CA', 'CH', 'JA', 'JH', 'NY', 'DD', 'NN', 'TA', 'TH', 'DA', 'DH', 'NA', 'PA', 'PH', 'BA', 'BH', 'MA', 'YA', 'RA', 'LA', 'WA', 'SA', 'HA', 'LL', 'AH', 'OU', 'AE'];
const MM_CHARS = ['က', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''];

protected const EN_NUMS = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'];
protected const MM_NUMS = ['', '', '', '', '', '', '', '', '', ''];
const EN_NUMS = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'];
const MM_NUMS = ['', '', '', '', '', '', '', '', '', ''];

protected const EN_TYPES = ['N'];
protected const MM_TYPES = ['နိုင်'];
const EN_TYPES = ['N'];
const MM_TYPES = ['နိုင်'];

protected const NAING = 'NAING';
protected const N = 'N';
const NAING = 'NAING';
const N = 'N';

protected const EN_TO_MM = 'en-to-mm';
protected const MM_TO_EN = 'mm-to-en';
const EN_TO_MM = 'en-to-mm';
const MM_TO_EN = 'mm-to-en';

protected const STATES = [
const STATES = [
[
'en' => 'Kachin',
'mm' => 'ကချင်ပြည်နယ်'
Expand Down
2 changes: 1 addition & 1 deletion src/Support/LaravelMyanmarTools/PhoneNumber.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

class PhoneNumber
{
protected string $phoneNo;
protected $phoneNo;

public function __construct(string $phoneNo)
{
Expand Down
2 changes: 1 addition & 1 deletion tests/Macro/RequestTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ public function it_can_normalize_nrc()
{
$request = $this->createRequest([
'nrc_en' => '12/OuKaMa(Naing)123456',
'nrc_mm' => '၁၂/ဥကမ(နိုင်)၁၂၃၄၅၆'
'nrc_mm' => '၁၂/ဥကမ(နိုင်)၁၂၃၄၅၆',
]);

$this->assertEquals(static::NRC_EN, $request->normalizeNrc('nrc_en'));
Expand Down

0 comments on commit 2e0e0a2

Please sign in to comment.