diff --git a/.github/ISSUE_TEMPLATE/Bug_report.md b/.github/ISSUE_TEMPLATE/Bug_report.md deleted file mode 100644 index 6e39c4c2..00000000 --- a/.github/ISSUE_TEMPLATE/Bug_report.md +++ /dev/null @@ -1,60 +0,0 @@ ---- -name: 🐞 Bug Report -about: Report a reproducible bug for mailcow. (NOT to be used for support questions.) -labels: bug ---- - - - -**Prior to placing the issue, please check following:** *(fill out each checkbox with an `X` once done)* -- [ ] I understand that not following or deleting the below instructions will result in immediate closure and/or deletion of my issue. -- [ ] I have understood that this bug report is dedicated for bugs, and not for support-related inquiries. -- [ ] I have understood that answers are voluntary and community-driven, and not commercial support. -- [ ] I have verified that my issue has not been already answered in the past. I also checked previous [issues](https://github.com/mailcow/mailcow-dockerized/issues). - -## Summary - - -## Logs - - -## Reproduction - - -## System information - - -| Question | Answer | -| --- | --- | -| My operating system | I_DO_REPLY_HERE | -| Is Apparmor, SELinux or similar active? | I_DO_REPLY_HERE | -| Virtualization technlogy (KVM, VMware, Xen, etc - **LXC and OpenVZ are not supported** | I_DO_REPLY_HERE | -| Server/VM specifications (Memory, CPU Cores) | I_DO_REPLY_HERE | -| Docker Version (`docker version`) | I_DO_REPLY_HERE | -| Docker-Compose Version (`docker-compose version`) | I_DO_REPLY_HERE | -| Reverse proxy (custom solution) | I_DO_REPLY_HERE | - -- Output of `git diff origin/master`, any other changes to the code? If so, **please post them**. -- All third-party firewalls and custom iptables rules are unsupported. *Please check the Docker docs about how to use Docker with your own ruleset*. Nevertheless, iptabels output can help us to help you: `iptables -L -vn`, `ip6tables -L -vn`, `iptables -L -vn -t nat` and `ip6tables -L -vn -t nat`. -- DNS problems? Please run `docker exec -it $(docker ps -qf name=acme-mailcow) dig +short stackoverflow.com @172.22.1.254` (set the IP accordingly, if you changed the internal mailcow network) and post the output. diff --git a/.github/ISSUE_TEMPLATE/Bug_report.yml b/.github/ISSUE_TEMPLATE/Bug_report.yml new file mode 100644 index 00000000..fee623be --- /dev/null +++ b/.github/ISSUE_TEMPLATE/Bug_report.yml @@ -0,0 +1,94 @@ +name: 🐞 Bug Report +description: Report a reproducible bug for mailcow. (NOT to be used for support questions.) +labels: ["bug"] +body: + - type: checkboxes + attributes: + label: Contribution guidelines + description: Please read the contribution guidelines before proceeding. + options: + - label: I've read the [contribution guidelines](https://github.com/mailcow/mailcow-dockerized/blob/master/CONTRIBUTING.md) and wholeheartedly agree + required: true + - type: checkboxes + attributes: + label: I've found a bug and checked that ... + description: Prior to placing the issue, please check following:** *(fill out each checkbox with an `X` once done)* + options: + - label: ... I understand that not following the below instructions will result in immediate closure and/or deletion of my issue. + required: true + - label: ... I have understood that this bug report is dedicated for bugs, and not for support-related inquiries. + required: true + - label: ... I have understood that answers are voluntary and community-driven, and not commercial support. + required: true + - label: ... I have verified that my issue has not been already answered in the past. I also checked previous [issues](https://github.com/mailcow/mailcow-dockerized/issues). + required: true + - type: textarea + attributes: + label: Description + description: Please provide a brief description of the bug in 1-2 sentences. If applicable, add screenshots to help explain your problem. Very useful for bugs in mailcow UI. + validations: + required: true + - type: textarea + attributes: + label: Logs + description: Please take a look at the [official documentation](https://mailcow.github.io/mailcow-dockerized-docs/debug-logs/) and post the last few lines of logs, when the error occurs. For example, docker container logs of affected containers. This will be automatically formatted into code, so no need for backticks. + render: bash + validations: + required: true + - type: textarea + attributes: + label: Steps to reproduce + description: Please describe the steps to reproduce the bug. Screenshots can be added, if helpful. + placeholder: |- + 1. ... + 2. ... + 3. ... + validations: + required: true + - type: textarea + attributes: + label: System information + description: In this stage we would kindly ask you to attach general system information about your setup. + value: |- + | Question | Answer | + | --- | --- | + | My operating system | I_DO_REPLY_HERE | + | Is Apparmor, SELinux or similar active? | I_DO_REPLY_HERE | + | Virtualization technlogy (KVM, VMware, Xen, etc - **LXC and OpenVZ are not supported** | I_DO_REPLY_HERE | + | Server/VM specifications (Memory, CPU Cores) | I_DO_REPLY_HERE | + | Docker Version (`docker version`) | I_DO_REPLY_HERE | + | Docker-Compose Version (`docker-compose version`) | I_DO_REPLY_HERE | + | Reverse proxy (custom solution) | I_DO_REPLY_HERE | + + Output of `git diff origin/master`, any other changes to the code? If so, **please post them**: + ``` + YOUR OUTPUT GOES HERE + ``` + + All third-party firewalls and custom iptables rules are unsupported. **Please check the Docker docs about how to use Docker with your own ruleset**. Nevertheless, iptabels output can help us to help you: + iptables -L -vn: + ``` + YOUR OUTPUT GOES HERE + ``` + + ip6tables -L -vn: + ``` + YOUR OUTPUT GOES HERE + ``` + + iptables -L -vn -t nat: + ``` + YOUR OUTPUT GOES HERE + ``` + + ip6tables -L -vn -t nat: + ``` + YOUR OUTPUT GOES HERE + ``` + + DNS problems? Please run `docker exec -it $(docker ps -qf name=acme-mailcow) dig +short stackoverflow.com @172.22.1.254` (set the IP accordingly, if you changed the internal mailcow network) and post the output: + ``` + YOUR OUTPUT GOES HERE + ``` + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/Feature_request.md b/.github/ISSUE_TEMPLATE/Feature_request.md deleted file mode 100644 index 64ff9d3a..00000000 --- a/.github/ISSUE_TEMPLATE/Feature_request.md +++ /dev/null @@ -1,29 +0,0 @@ ---- -name: 💡 Feature Request -about: Suggest an idea for mailcow. -labels: enhancement ---- - - - -## Summary - -A clear and concise description of what the problem is. -For example: I'm always frustrated when [...] - -## Motivation - -What are you about to solve or improve with this idea? -What would be the benefit for most users? - -## Additional context - -Add any other context or screenshots about the feature request. diff --git a/.github/ISSUE_TEMPLATE/Feature_request.yml b/.github/ISSUE_TEMPLATE/Feature_request.yml new file mode 100644 index 00000000..39414f1b --- /dev/null +++ b/.github/ISSUE_TEMPLATE/Feature_request.yml @@ -0,0 +1,20 @@ +name: 💡 Feature Request +description: Suggest an idea for mailcow. +labels: ["enhancement"] +body: + - type: textarea + attributes: + label: Summary + description: Please describe your idea in a reasonable amount of detail. + validations: + required: true + - type: textarea + attributes: + label: Motivation + description: Please describe how your idea would benefit you and other users. + validations: + required: true + - type: textarea + attributes: + label: Additional context + description: Add any other context or screenshots about the feature request. diff --git a/.github/workflows/close_old_issues_and_prs.yml b/.github/workflows/close_old_issues_and_prs.yml index 76c93159..e746bc6f 100644 --- a/.github/workflows/close_old_issues_and_prs.yml +++ b/.github/workflows/close_old_issues_and_prs.yml @@ -14,7 +14,7 @@ jobs: pull-requests: write steps: - name: Mark/Close Stale Issues and Pull Requests 🗑️ - uses: actions/stale@v4 + uses: actions/stale@v5.0.0 with: repo-token: ${{ secrets.STALE_ACTION_PAT }} days-before-stale: 60 diff --git a/README.md b/README.md index 7e79eac6..7abd1024 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,7 @@ # mailcow: dockerized - 🐮 + 🐋 = 💕 + +## We stand with 🇺🇦 + [![master build status](https://img.shields.io/drone/build/mailcow/mailcow-dockerized/master?label=master%20build&server=https%3A%2F%2Fdrone.mailcow.email)](https://drone.mailcow.email/mailcow/mailcow-dockerized) [![staging build status](https://img.shields.io/drone/build/mailcow/mailcow-dockerized/staging?label=staging%20build&server=https%3A%2F%2Fdrone.mailcow.email)](https://drone.mailcow.email/mailcow/mailcow-dockerized) [![Translation status](https://translate.mailcow.email/widgets/mailcow-dockerized/-/translation/svg-badge.svg)](https://translate.mailcow.email/engage/mailcow-dockerized/) [![Twitter URL](https://img.shields.io/twitter/url/https/twitter.com/mailcow_email.svg?style=social&label=Follow%20%40mailcow_email)](https://twitter.com/mailcow_email) diff --git a/data/Dockerfiles/clamd/Dockerfile b/data/Dockerfiles/clamd/Dockerfile index 6f38e359..42d0ce97 100644 --- a/data/Dockerfiles/clamd/Dockerfile +++ b/data/Dockerfiles/clamd/Dockerfile @@ -1,60 +1,15 @@ -FROM debian:bullseye-slim +FROM clamav/clamav:0.104.2-2_base LABEL maintainer "André Peters " -ARG CLAMAV=0.103.5 -RUN apt-get update && apt-get install -y --no-install-recommends \ - ca-certificates \ - zlib1g-dev \ - libcurl4-openssl-dev \ - libncurses5-dev \ - libzip-dev \ - libpcre2-dev \ - libxml2-dev \ - libssl-dev \ - build-essential \ - libjson-c-dev \ - curl \ - bash \ - wget \ - tzdata \ - dnsutils \ +RUN apk upgrade --no-cache \ + && apk add --update --no-cache \ rsync \ - dos2unix \ - netcat \ - && rm -rf /var/lib/apt/lists/* \ - && wget -O - https://www.clamav.net/downloads/production/clamav-${CLAMAV}.tar.gz | tar xfvz - \ - && cd clamav-${CLAMAV} \ - && ./configure \ - --prefix=/usr \ - --libdir=/usr/lib \ - --sysconfdir=/etc/clamav \ - --mandir=/usr/share/man \ - --infodir=/usr/share/info \ - --disable-llvm \ - --with-user=clamav \ - --with-group=clamav \ - --with-dbdir=/var/lib/clamav \ - --enable-clamdtop \ - --enable-bigstack \ - --with-pcre \ - && make -j4 \ - && make install \ - && make clean \ - && cd .. && rm -rf clamav-${CLAMAV} \ - && apt-get -y --auto-remove purge build-essential \ - && apt-get -y purge zlib1g-dev \ - libncurses5-dev \ - libzip-dev \ - libpcre2-dev \ - libxml2-dev \ - libssl-dev \ - libjson-c-dev \ - && addgroup --system --gid 700 clamav \ - && adduser --system --no-create-home --home /var/lib/clamav --uid 700 --gid 700 --disabled-login clamav \ - && rm -rf /tmp/* /var/tmp/* + bind-tools \ + bash COPY clamd.sh ./ -COPY tini /sbin/tini +RUN chmod +x /sbin/tini -CMD ["/sbin/tini", "-g", "--", "/clamd.sh"] +ENTRYPOINT [] +CMD ["/sbin/tini", "-g", "--", "/clamd.sh"] \ No newline at end of file diff --git a/data/Dockerfiles/clamd/clamd.sh b/data/Dockerfiles/clamd/clamd.sh index 10df8072..3545e688 100755 --- a/data/Dockerfiles/clamd/clamd.sh +++ b/data/Dockerfiles/clamd/clamd.sh @@ -14,10 +14,10 @@ rm -rf /var/lib/clamav/clamav-*.tmp mkdir -p /run/clamav /var/lib/clamav -if [[ -s /etc/clamav/whitelist.ign2 ]]; then - echo "Copying non-empty whitelist.ign2 to /var/lib/clamav/whitelist.ign2" - cp /etc/clamav/whitelist.ign2 /var/lib/clamav/whitelist.ign2 -fi +#if [[ -s /etc/clamav/whitelist.ign2 ]]; then +# echo "Copying non-empty whitelist.ign2 to /var/lib/clamav/whitelist.ign2" +# cp /etc/clamav/whitelist.ign2 /var/lib/clamav/whitelist.ign2 +#fi if [[ ! -f /var/lib/clamav/whitelist.ign2 ]]; then echo "Creating /var/lib/clamav/whitelist.ign2" diff --git a/data/Dockerfiles/clamd/tini b/data/Dockerfiles/clamd/tini deleted file mode 100755 index 03af82f0..00000000 Binary files a/data/Dockerfiles/clamd/tini and /dev/null differ diff --git a/data/Dockerfiles/dovecot/Dockerfile b/data/Dockerfiles/dovecot/Dockerfile index ee30eec8..4a914904 100644 --- a/data/Dockerfiles/dovecot/Dockerfile +++ b/data/Dockerfiles/dovecot/Dockerfile @@ -1,10 +1,10 @@ -FROM debian:buster-slim +FROM debian:bullseye-slim LABEL maintainer "Andre Peters " ARG DEBIAN_FRONTEND=noninteractive -ARG DOVECOT=2.3.17.1 +ARG DOVECOT=2.3.18 ENV LC_ALL C -ENV GOSU_VERSION 1.12 +ENV GOSU_VERSION 1.14 # Add groups and users before installing Dovecot to not break compatibility RUN groupadd -g 5000 vmail \ @@ -89,7 +89,7 @@ RUN groupadd -g 5000 vmail \ && chmod +x /usr/local/bin/gosu \ && gosu nobody true \ && apt-key adv --fetch-keys https://repo.dovecot.org/DOVECOT-REPO-GPG \ - && echo "deb https://repo.dovecot.org/ce-${DOVECOT}/debian/buster buster main" > /etc/apt/sources.list.d/dovecot.list \ + && echo "deb https://repo.dovecot.org/ce-${DOVECOT}/debian/bullseye bullseye main" > /etc/apt/sources.list.d/dovecot.list \ && apt-get update \ && apt-get -y --no-install-recommends install \ dovecot-lua \ diff --git a/data/Dockerfiles/dovecot/imapsync b/data/Dockerfiles/dovecot/imapsync index 07cf58e7..0d34504e 100755 --- a/data/Dockerfiles/dovecot/imapsync +++ b/data/Dockerfiles/dovecot/imapsync @@ -1,6 +1,6 @@ #!/usr/bin/env perl -# $Id: imapsync,v 2.148 2021/07/22 14:21:09 gilles Exp gilles $ +# $Id: imapsync,v 2.178 2022/01/12 21:28:37 gilles Exp gilles $ # structure # pod documentation # use pragmas @@ -25,7 +25,7 @@ and without duplicates. =head1 VERSION -This documentation refers to Imapsync $Revision: 2.148 $ +This documentation refers to Imapsync $Revision: 2.178 $ =head1 USAGE @@ -212,16 +212,6 @@ Same thing for user2 password. --sslargs2 str : Pass any ssl parameter for host2 ssl or tls connection. See --sslargs1 - --timeout1 flo : Connection timeout in seconds for host1. - Default is 120 and 0 means no timeout at all. - --timeout2 flo : Connection timeout in seconds for host2. - Default is 120 and 0 means no timeout at all. - - Caveat, under CGI context, you may encounter a timeout - from the webserver, killing imapsync and the imap connexions. - See the document INSTALL.OnlineUI.txt and search - for "Timeout" for how to deal with this issue. - =head2 OPTIONS/authentication @@ -243,7 +233,7 @@ Same thing for user2 password. --domain2 str : Domain on host2 (NTLM authentication). --oauthaccesstoken1 str : The access token to authenticate with OAUTH2. - It will be combined with the --user1 value to form the + It will be combined with the --user1 value to form the string to pass with XOAUTH2 authentication. The password given by --password1 or --passfile1 is ignored. @@ -252,18 +242,18 @@ Same thing for user2 password. If the value is a file, imapsync reads its first line and take this line as the access token. The advantage of the file is that if the access token changes then - imapsync can read it again when it needs to reconnect + imapsync can read it again when it needs to reconnect during a run. - --oauthaccesstoken2 str : same thing as --oauthaccesstoken1 + --oauthaccesstoken2 str : same thing as --oauthaccesstoken1 --oauthdirect1 str : The direct string to pass with XOAUTH2 authentication. - The password given by --password1 or --passfile1 and + The password given by --password1 or --passfile1 and the user given by --user1 are ignored. --oauthdirect2 str : same thing as oauthdirect1 - + =head2 OPTIONS/folders @@ -432,6 +422,12 @@ and user1 user2 are the --user1 --user2 values. by spaces. --regexmess reg : and this one, etc. + --truncmess int : truncates messages when their size exceed the int + value, specified in bytes. Good to sync too big + messages or to "suppress" attachments. + Have in mind that this way, messages become + uncoherent somehow. + =head2 OPTIONS/labels Gmail present labels as folders in imap. Imapsync can accelerate the sync @@ -639,7 +635,27 @@ https://imapsync.lamiral.info/FAQ.d/FAQ.Gmail.txt =head2 OPTIONS/behavior - --maxmessagespersecond flo : limits the average number of messages + --timeout1 flo : Connection timeout in seconds for host1. + Default is 120 and 0 means no timeout at all. + --timeout2 flo : Connection timeout in seconds for host2. + Default is 120 and 0 means no timeout at all. + + Caveat, under CGI context, you may encounter a timeout + from the webserver, killing imapsync and the imap connexions. + See the document INSTALL.OnlineUI.txt and search + for "Timeout" for how to deal with this issue. + + --keepalive1 : https://metacpan.org/pod/Mail::IMAPClient#Keepalive + Some firewalls and network gears like to timeout connections + prematurely if the connection sits idle. + This option enables SO_KEEPALIVE on the host1 socket. + --keepalive1 is on by default since imapsync release 2.169 + Use --nokeepalive1 to disable it. + + --keepalive2 : Same as --keepalive2 but for host2. + Use --nokeepalive2 to disable it. + + --maxmessagespersecond flo : limits the average number of messages transferred per second. --maxbytespersecond int : limits the average transfer rate per second. @@ -946,6 +962,7 @@ use strict ; use warnings ; use Carp ; use Cwd ; +use Compress::Zlib ; use Data::Dumper ; use Digest::HMAC_SHA1 qw( hmac_sha1 hmac_sha1_hex ) ; use Digest::MD5 qw( md5 md5_hex md5_base64 ) ; @@ -1033,6 +1050,7 @@ Readonly my $EXIT_ERR_SELECT => 117 ; Readonly my $EXIT_TRANSFER_EXCEEDED => 118 ; Readonly my $EXIT_ERR_APPEND_VIRUS => 119 ; +Readonly my $EXIT_ERR_FLAGS => 120 ; Readonly my $EXIT_TESTS_FAILED => 254 ; # Like Test::More API @@ -1063,6 +1081,7 @@ Readonly my %EXIT_TXT => ( $EXIT_ERR_APPEND => 'EXIT_ERR_APPEND', $EXIT_ERR_APPEND_VIRUS => 'EXIT_ERR_APPEND_VIRUS', $EXIT_ERR_FETCH => 'EXIT_ERR_FETCH', + $EXIT_ERR_FLAGS => 'EXIT_ERR_FLAGS', $EXIT_ERR_CREATE => 'EXIT_ERR_CREATE', $EXIT_ERR_SELECT => 'EXIT_ERR_SELECT', $EXIT_TESTS_FAILED => 'EXIT_TESTS_FAILED', @@ -1082,6 +1101,7 @@ Readonly my %EXIT_VALUE_OF_ERR_TYPE => ( ERR_CREATE => $EXIT_ERR_CREATE, ERR_SELECT => $EXIT_ERR_SELECT, ERR_Host1_FETCH => $EXIT_ERR_FETCH, + ERR_FLAGS => $EXIT_ERR_FLAGS, ERR_UNCLASSIFIED => $EXIT_WITH_ERRORS, ERR_NOTHING_REPORTED => $EXIT_WITH_ERRORS, ERR_TRANSFER_EXCEEDED => $EXIT_TRANSFER_EXCEEDED, @@ -1093,6 +1113,103 @@ Readonly my %EXIT_VALUE_OF_ERR_TYPE => ( ) ; + +Readonly my %COMMENT_OF_ERR_TYPE => ( + ERR_APPEND_SIZE => \&comment_err_append_size, + ERR_OVERQUOTA => \&comment_err_overquota, + ERR_APPEND => \&comment_err_blank, + ERR_APPEND_VIRUS => \&comment_err_blank, + ERR_CREATE => \&comment_err_blank, + ERR_SELECT => \&comment_err_blank, + ERR_Host1_FETCH => \&comment_err_blank, + ERR_FLAGS => \&comment_err_flags, + ERR_UNCLASSIFIED => \&comment_err_blank, + ERR_NOTHING_REPORTED => \&comment_err_blank, + ERR_TRANSFER_EXCEEDED => \&comment_err_transfer_exceeded, + ERR_CONNECTION_FAILURE_HOST1 => \&comment_err_connection_failure_host1, + ERR_CONNECTION_FAILURE_HOST2 => \&comment_err_connection_failure_host2, + ERR_AUTHENTICATION_FAILURE_USER1 => \&comment_err_authentication_failure_host1, + ERR_AUTHENTICATION_FAILURE_USER2 => \&comment_err_authentication_failure_host2, + ERR_EXIT_TLS_FAILURE => \&comment_err_blank, +) ; + + +sub comment_err_blank +{ + return '' ; +} + + +sub comment_err_append_size +{ + my $mysync = shift @ARG ; + + my $comment = "The destination server refuses too big messages. Use --truncmess option. Read https://imapsync.lamiral.info/FAQ.d/FAQ.Messages_Too_Big.txt" ; + return $comment ; +} + + +sub comment_err_authentication_failure_host1 +{ + my $mysync = shift @ARG ; + + my $comment = "Check the credentials for $mysync->{ user1 }." ; + return $comment ; +} + +sub comment_err_authentication_failure_host2 +{ + my $mysync = shift @ARG ; + + my $comment = "Check the credentials for $mysync->{ user2 }." ; + return $comment ; +} + + +sub comment_err_connection_failure_host1 +{ + my $mysync = shift @ARG ; + + my $comment = "Check that host1 $mysync->{ host1 } on port $mysync->{ port1 } is the right IMAP server to be contacted for your mailbox." ; + return $comment ; +} + +sub comment_err_connection_failure_host2 +{ + my $mysync = shift @ARG ; + + my $comment = "Check that host1 $mysync->{ host2 } on port $mysync->{ port2 } is the right IMAP server to be contacted for your mailbox." ; + return $comment ; +} + +sub comment_err_overquota +{ + my $mysync = shift @ARG ; + + my $comment = 'The destination mailbox is 100% full, get free space on it and then resume the sync.' ; + return $comment ; +} + + +sub comment_err_transfer_exceeded +{ + my $mysync = shift @ARG ; + + my $size_limit_human = bytes_display_string_dec( $mysync->{ exitwhenover } ) ; + my $comment = "The maximum transfer size for a single sync is reached ( over $size_limit_human ). Relaunch the sync to sync more." ; + return $comment ; +} + +sub comment_err_flags +{ + my $mysync = shift @ARG ; + + my $comment = 'Many STORE errors with FLAGS. Retry with the option --noresyncflags' ; + return $comment ; +} + + + Readonly my $DEFAULT_LOGDIR => 'LOG_imapsync' ; Readonly my $ERRORS_MAX => 50 ; # exit after 50 errors. @@ -1177,9 +1294,8 @@ Readonly my $FORCE => 1 ; my( $sync, $acc1, $acc2, - $debugcontent, $debugflags, + $debugflags, $debuglist, $debugdev, $debugmaxlinelength, $debugcgi, - @include, @exclude, @folderrec, @folderfirst, @folderlast, @h1_folders_all, %h1_folders_all, @@ -1191,41 +1307,26 @@ my( %h1_subscribed_folder, %h2_subscribed_folder, %h2_folders_from_1_wanted, %h2_folders_from_1_several, - $prefix1, $prefix2, @regexmess, @skipmess, @pipemess, $pipemesscheck, $syncflagsaftercopy, $syncinternaldates, $idatefromheader, - $minsize, $maxage, $minage, $search, @useheader, %useheader, $skipsize, $allowsizemismatch, $buffersize, - - $authmd5, $authmd51, $authmd52, $subscribed, $subscribe, $subscribeall, $help, - - $fast, - $nb_msg_skipped_dry_mode, - $h2_nb_msg_noheader, - $h1_bytes_processed, - $h1_nb_msg_end, $h1_bytes_end, $h2_nb_msg_end, $h2_bytes_end, - $timestart_int, - $uid1, $uid2, - - $split1, $split2, - $modulesversion, $delete2folders, $delete2foldersonly, $delete2foldersbutnot, $usecache, $debugcache, $cacheaftercopy, @@ -1244,7 +1345,6 @@ my( $cgidir, %month_abrev, $SSL_VERIFY_POLICY, - $warn_release, ) ; single_sync( $sync, $acc1, $acc2 ); @@ -1263,7 +1363,7 @@ sub single_sync # or $acc1->{variable_name} # or $acc1->{variable_name} -# +# $acc1 = {} ; $acc2 = {} ; $sync->{ acc1 } = $acc1 ; @@ -1271,10 +1371,12 @@ $sync->{ acc2 } = $acc2 ; $acc1->{ Side } = 'Host1' ; $acc2->{ Side } = 'Host2' ; +$acc1->{ N } = '1' ; +$acc2->{ N } = '2' ; $sync->{timestart} = time ; # Is a float because of use Time::HiRres -$sync->{rcs} = q{$Id: imapsync,v 2.148 2021/07/22 14:21:09 gilles Exp gilles $} ; +$sync->{rcs} = q{$Id: imapsync,v 2.178 2022/01/12 21:28:37 gilles Exp gilles $} ; $sync->{ memory_consumption_at_start } = memory_consumption( ) || 0 ; @@ -1383,6 +1485,8 @@ after_get_options( $sync, $options_good ) ; # Under CGI environment, fix caveat emptor potential issues cgisetcontext( $sync ) ; +get_options_extra( $sync ) ; + # --gmail --gmail --exchange --office etc. easyany( $sync ) ; @@ -1397,7 +1501,7 @@ my $unittestssuite = unittestssuite( $sync ) ; if ( condition_to_leave_after_tests( $sync ) ) { - return $unittestssuite ; + return $unittestssuite ; } # init live varaiables @@ -1458,7 +1562,7 @@ myprint( 'Effective user id is ' . getpwuid_any_os( $EFFECTIVE_USER_ID ). " (eui $modulesversion = defined $modulesversion ? $modulesversion : 1 ; -$warn_release = ( $sync->{releasecheck} ) ? check_last_release( ) : $STR_use_releasecheck ; +$sync->{ warn_release } = ( $sync->{ releasecheck } ) ? check_last_release( ) : $STR_use_releasecheck ; $wholeheaderifneeded = defined $wholeheaderifneeded ? $wholeheaderifneeded : 1; @@ -1557,7 +1661,7 @@ check_lib_version( $sync ) or -if ( $sync->{ justbanner } ) +if ( $sync->{ justbanner } ) { myprint( "Exiting because of --justbanner\n" ) ; exit_clean( $sync, $EX_OK ) ; @@ -1766,6 +1870,11 @@ myprint( "Host1: imap connection timeout is $sync->{ acc1 }->{timeout} seconds\n $sync->{ acc2 }->{timeout} = defined $sync->{ acc2 }->{timeout} ? $sync->{ acc2 }->{timeout} : $sync->{ timeout } ; myprint( "Host2: imap connection timeout is $sync->{ acc2 }->{timeout} seconds\n" ) ; + +keepalive1( $sync ) ; +keepalive2( $sync ) ; + + if ( under_cgi_context( $sync ) ) { myprint( "Under CGI context, a timeout can occur from the webserver, see https://imapsync.lamiral.info/INSTALL.d/INSTALL.OnlineUI.txt\n" ) ; @@ -1773,7 +1882,7 @@ if ( under_cgi_context( $sync ) ) $sync->{ syncacls } = defined $sync->{ syncacls } ? $sync->{ syncacls } : 0 ; -# No folders sizes if --justfolders, unless really wanted. +# No folders sizes at the beginning if --justfolders, unless really wanted. if ( $sync->{ justfolders } and not defined $sync->{ foldersizes } @@ -1786,7 +1895,8 @@ if ( $sync->{ foldersizes } = ( defined $sync->{ foldersizes } ) ? $sync->{ foldersizes } : 1 ; $sync->{ foldersizesatend } = ( defined $sync->{ foldersizesatend } ) ? $sync->{ foldersizesatend } : $sync->{ foldersizes } ; -$sync->{ checknoabletosearch } = ( defined $sync->{ checknoabletosearch } ) ? $sync->{ checknoabletosearch } : 1 ; +#$sync->{ checknoabletosearch } = ( defined $sync->{ checknoabletosearch } ) ? $sync->{ checknoabletosearch } : 1 ; +set_checknoabletosearch( $sync ) ; $acc1->{ fastio } = defined $acc1->{ fastio } ? $acc1->{ fastio } : 0 ; @@ -1796,6 +1906,11 @@ $acc2->{ fastio } = defined $acc2->{ fastio } ? $acc2->{ fastio } : 0 ; $acc1->{ reconnectretry } = defined $acc1->{ reconnectretry } ? $acc1->{ reconnectretry } : $DEFAULT_NB_RECONNECT_PER_IMAP_COMMAND ; $acc2->{ reconnectretry } = defined $acc2->{ reconnectretry } ? $acc2->{ reconnectretry } : $DEFAULT_NB_RECONNECT_PER_IMAP_COMMAND ; +# IMAP compression on by default +#$acc1->{ compress } = defined $acc1->{ compress } ? $acc1->{ compress } : 0 ; +#$acc2->{ compress } = defined $acc2->{ compress } ? $acc2->{ compress } : 0 ; + + if ( ! @useheader ) { @useheader = qw( Message-Id Received ) ; } @@ -1936,6 +2051,9 @@ quota( $sync, $sync->{imap2}, 'h2' ) ; maxsize_setting( $sync ) ; +acc_compress_imap( $acc1 ) ; +acc_compress_imap( $acc2 ) ; + if ( $sync->{ justlogin } ) { $sync->{imap1}->logout( ) ; $sync->{imap2}->logout( ) ; @@ -2330,7 +2448,7 @@ FOLDER: foreach my $h1_fold ( @{ $sync->{h1_folders_wanted} } ) my $h2_fold_nb_messages = count_from_select( @select_results ) ; myprint( "Host2: folder [$h2_fold] has $h2_fold_nb_messages messages in total (mentioned by SELECT)\n" ) ; - my $permanentflags2 = permanentflags( @select_results ) ; + my $permanentflags2 = permanentflags( $sync, @select_results ) ; myprint( "Host2: folder [$h2_fold] permanentflags: $permanentflags2\n" ) ; if ( $sync->{ expunge1 } ) @@ -2874,22 +2992,21 @@ if ( ! lost_connection( $sync, $sync->{imap2}, "for host2 [$sync->{host2}]" ) ) do_and_print_stats( $sync ) ; -if ( $sync->{errorsdump} and $sync->{nb_errors} ) +if ( $sync->{ nb_errors } ) { myprint( errors_listing( $sync ) ) ; } -if ( $sync->{testslive} or $sync->{testslive6} ) +if ( $sync->{ testslive } or $sync->{ testslive6 } ) { - tests_live_result( $sync->{nb_errors} ) ; + tests_live_result( $sync->{ nb_errors } ) ; } - -if ( $sync->{nb_errors} ) +if ( $sync->{ nb_errors } ) { - my $exit_value = $EXIT_VALUE_OF_ERR_TYPE{ $sync->{most_common_error} } || $EXIT_CATCH_ALL ; + my $exit_value = exit_value( $sync, $sync->{ most_common_error } ) ; exit_clean( $sync, $exit_value ) ; } else @@ -3020,16 +3137,16 @@ sub tests_print_output_if_needed output( $mysync, "Hello\n" ) ; is( "Hello\n", print_output_if_needed( $mysync ), 'print_output_if_needed: Hello => Hello' ) ; - + $mysync->{ dockercontext } = 1 ; is( "Hello\n", print_output_if_needed( $mysync ), 'print_output_if_needed: dockercontext + Hello => Hello' ) ; - + $mysync->{ version } = 1 ; is( q{}, print_output_if_needed( $mysync ), 'print_output_if_needed: dockercontext + Hello + --version => ""' ) ; - + $mysync->{ dockercontext } = 0 ; is( "Hello\n", print_output_if_needed( $mysync ), 'print_output_if_needed: Hello + --version => Hello' ) ; - + note( 'Leaving tests_print_output_if_needed()' ) ; return ; } @@ -3037,11 +3154,11 @@ sub tests_print_output_if_needed sub print_output_if_needed { - + my $mysync = shift @ARG ; if ( ! defined $mysync ) { return ; } my $output = output( $mysync ) ; - + if ( $mysync->{ version } && under_docker_context( $mysync ) ) { return q{} ; @@ -3051,7 +3168,7 @@ sub print_output_if_needed myprint( $output ) ; return $output ; } - + } @@ -3415,7 +3532,7 @@ sub tests_under_docker_context sub under_docker_context { my $mysync = shift ; - + if ( ! defined $mysync ) { return ; } if ( defined $mysync->{ dockercontext } ) @@ -3436,7 +3553,7 @@ sub under_docker_context } -sub docker_context +sub docker_context { my $mysync = shift ; @@ -3447,7 +3564,7 @@ sub docker_context output( $mysync, "Docker context detected with the file /.dockerenv\n" ) ; # No pidfile by default - + $mysync->{ pidfile } = defined( $mysync->{ pidfile } ) ? $mysync->{ pidfile } : q{} ; # No log by default if ( defined( $mysync->{ log } ) ) @@ -3461,8 +3578,11 @@ sub docker_context } # In case something is written relatively to . - output( $mysync, "Changing current directory to /var/tmp/\n" ) ; - chdir '/var/tmp/' ; + my $tmp_dir = "/var/tmp/uid_$EFFECTIVE_USER_ID" ; + mkpath( $tmp_dir ) ; # silly? No. it is for imapsync --version being ok. + do_valid_directory( $tmp_dir ) ; + output( $mysync, "Changing current directory to $tmp_dir\n" ) ; + chdir $tmp_dir ; return ; } @@ -3520,7 +3640,7 @@ sub under_cgi_context return ; } -sub cgibuildheader +sub cgibuildheader { my $mysync = shift ; if ( ! under_cgi_context( $mysync ) ) { return ; } @@ -3689,15 +3809,15 @@ sub cgisetcontext if ( ! under_cgi_context( $mysync ) ) { return ; } output( $mysync, "Under cgi context\n" ) ; - - + + set_umask( $mysync ) ; # Remove all content in unsafe evaled options @{ $mysync->{ regextrans2 } } = ( ) ; @{ $mysync->{ regexflag } } = buggyflagsregex( ) ; - + @regexmess = ( ) ; @skipmess = ( ) ; @pipemess = ( ) ; @@ -3738,7 +3858,7 @@ sub cgisetcontext -d $cgidir or mkpath $cgidir or die "Can not create $cgidir: $OS_ERROR\n" ; $mysync->{ tmpdir } = $cgidir ; $mysync->{ logdir } = '' ; - + chdir $cgidir or die "Can not cd to $cgidir: $OS_ERROR\n" ; cgioutputenvcontext( $mysync ) ; $mysync->{ debug } and output( $mysync, 'Current directory is ' . getcwd( ) . "\n" ) ; @@ -3758,7 +3878,7 @@ sub cgisetcontext # addheader on by default $mysync->{ addheader } = defined $mysync->{ addheader } ? $mysync->{ addheader } : 1 ; - + # sync duplicates by default in cgi context $mysync->{ syncduplicates } = defined $mysync->{ syncduplicates } ? $mysync->{ syncduplicates } : 1 ; @@ -3780,7 +3900,7 @@ sub cgioutputenvcontext return ; } -sub announcelogfile +sub announcelogfile { my $mysync = shift ; @@ -3792,7 +3912,7 @@ sub announcelogfile else { myprint( "No log file because of option --nolog\n" ) ; - } + } return ; } @@ -3802,7 +3922,7 @@ sub loglogfile my $mysync = shift ; if ( ! $mysync->{ loglogfile } ) { return ; } if ( ! $mysync->{ log } ) { return ; } - + my $cwd = getcwd( ) ; my $absolutelogfilepath ; # Fixme: add case when the logfile name is already absolute @@ -3822,10 +3942,10 @@ sub loglogfile } -sub checkselectable +sub checkselectable { - my $mysync = shift ; - + my $mysync = shift ; + if ( $mysync->{ checkselectable } ) { my @h1_folders_wanted_selectable ; myprint( "Host1: Checking wanted folders are selectable. Use --nocheckselectable to avoid this check.\n" ) ; @@ -3842,7 +3962,7 @@ sub checkselectable } } @{ $mysync->{ h1_folders_wanted } } = @h1_folders_wanted_selectable ; - ( $mysync->{ debug } or $mysync->{ debugfolders } ) + ( $mysync->{ debug } or $mysync->{ debugfolders } ) and myprint( 'Host1: checking folders took ', timenext( $mysync ), " s\n" ) ; } else @@ -3852,14 +3972,14 @@ sub checkselectable return ; } -sub setcheckselectable +sub setcheckselectable { my $mysync = shift ; - + my $h1_folders_wanted_nb = scalar @{ $mysync->{ h1_folders_wanted } } ; # 152 because 98% of host1 accounts have less than 152 folders on /X service. - # command to get this value: - # datamash_file_op_index G_Host1_Nb_folders.txt perc:98 4 %16.1f + # command to get this value: + # datamash_file_op_index G_Host1_Nb_folders.txt perc:98 4 %16.1f if ( ! defined $mysync->{ checkselectable } ) { if ( 152 >= $h1_folders_wanted_nb ) @@ -4014,8 +4134,8 @@ sub foldersizes } myprintf( "%s Nb folders: %11s folders\n", $side, $nb_folders ) ; myprintf( "%s Nb messages: %11s messages\n", $side, $total_nb ) ; - myprintf( "%s Total size: %11s bytes (%s)\n", $side, $total_size, bytes_display_string( $total_size ) ) ; - myprintf( "%s Biggest message: %11s bytes (%s)\n", $side, $biggest_in_all, bytes_display_string( $biggest_in_all ) ) ; + myprintf( "%s Total size: %11s bytes (%s)\n", $side, $total_size, bytes_display_string_bin( $total_size ) ) ; + myprintf( "%s Biggest message: %11s bytes (%s)\n", $side, $biggest_in_all, bytes_display_string_bin( $biggest_in_all ) ) ; myprintf( "%s Time spent on sizing: %11.1f seconds\n", $side, timenext( $mysync ) ) ; return( $total_nb, $total_size ) ; } @@ -4319,11 +4439,11 @@ sub foldersizes_total myprintf( "Host1 Nb messages: %11s messages\n", $total_nb_1 ) ; myprintf( "Host2 Nb messages: %11s messages\n", $total_nb_2 ) ; myprint( "\n" ) ; - myprintf( "Host1 Total size: %11s bytes (%s)\n", $total_size_1, bytes_display_string( $total_size_1 ) ) ; - myprintf( "Host2 Total size: %11s bytes (%s)\n", $total_size_2, bytes_display_string( $total_size_2 ) ) ; + myprintf( "Host1 Total size: %11s bytes (%s)\n", $total_size_1, bytes_display_string_bin( $total_size_1 ) ) ; + myprintf( "Host2 Total size: %11s bytes (%s)\n", $total_size_2, bytes_display_string_bin( $total_size_2 ) ) ; myprint( "\n" ) ; - myprintf( "Host1 Biggest message: %11s bytes (%s)\n", $biggest_in_all_1, bytes_display_string( $biggest_in_all_1 ) ) ; - myprintf( "Host2 Biggest message: %11s bytes (%s)\n", $biggest_in_all_2, bytes_display_string( $biggest_in_all_2 ) ) ; + myprintf( "Host1 Biggest message: %11s bytes (%s)\n", $biggest_in_all_1, bytes_display_string_bin( $biggest_in_all_1 ) ) ; + myprintf( "Host2 Biggest message: %11s bytes (%s)\n", $biggest_in_all_2, bytes_display_string_bin( $biggest_in_all_2 ) ) ; myprint( "\n" ) ; myprintf( "Time spent on sizing: %11.1f seconds\n", timenext( $mysync ) ) ; @@ -5326,7 +5446,7 @@ sub imapsync_id vendor => 'Gilles LAMIRAL', 'support-url' => 'https://imapsync.lamiral.info/', # Example of date-time: 19-Sep-2015 08:56:07 - date => date_from_rcs( q{$Date: 2021/07/22 14:21:09 $ } ), + date => date_from_rcs( q{$Date: 2022/01/12 21:28:37 $ } ), } ; my $imapsync_id_github = { @@ -5335,7 +5455,7 @@ sub imapsync_id os => $OSNAME, vendor => 'github', 'support-url' => 'https://github.com/imapsync/imapsync', - date => date_from_rcs( q{$Date: 2021/07/22 14:21:09 $ } ), + date => date_from_rcs( q{$Date: 2022/01/12 21:28:37 $ } ), } ; $imapsync_id = $imapsync_id_lamiral ; @@ -5412,11 +5532,13 @@ sub quota my $Side = $side{ $side } ; my $debug_before = $imap->Debug( ) ; $imap->Debug( 1 ) ; - if ( not $imap->has_capability( 'QUOTA' ) ) { + if ( not $imap->has_capability( 'QUOTA' ) ) + { + myprint( "$Side: No QUOTA capability found, skipping it.\n" ) ; $imap->Debug( $debug_before ) ; return ; } ; - myprint( "\n$Side: found quota, presented in raw IMAP\n" ) ; + myprint( "\n$Side: QUOTA capability found, presented in raw IMAP on next lines\n" ) ; my $getquotaroot = $imap->getquotaroot( 'INBOX' ) ; # Gmail INBOX quotaroot is "" but with it Mail::IMAPClient does a literal GETQUOTA {2} \n "" #$imap->quota( 'ROOT' ) ; @@ -5517,7 +5639,7 @@ sub automap $mysync->{h2_special} = special_from_folders_hash( $mysync, $mysync->{imap2}, 'Host2' ) ; build_possible_special( $mysync ) ; - build_guess_special( $mysync ) ; + build_guess_special( $mysync ) ; build_automap( $mysync ) ; return ; @@ -5653,7 +5775,7 @@ sub build_possible_special 'Junk E-Mail', 'Junk Email'] ; $possible_special->{'\Sent'} = [ 'Sent', 'Sent Messages', 'Sent Items', 'Gesendete Elemente', 'Gesendete Objekte', - '&AMk-l&AOk-ments envoy&AOk-s', 'Envoy&AOk-', 'Objets envoy&AOk-s', + '&AMk-l&AOk-ments envoy&AOk-s', 'E&AwE-le&AwE-ments envoye&AwE-s', 'Envoy&AOk-', 'Objets envoy&AOk-s', 'Elementos enviados', '&kAFP4W4IMH8wojCkMMYw4A-', '&BB4EQgQ,BEAEMAQyBDsENQQ9BD0ESwQ1-', @@ -5728,32 +5850,6 @@ sub special_from_folders_hash return( \%special ) ; } -sub errors_incr -{ - my ( $mysync, @error ) = @ARG ; - $mysync->{nb_errors}++ ; - - if ( @error ) { - errors_log( $mysync, @error ) ; - myprint( @error ) ; - } - - $mysync->{errorsmax} ||= $ERRORS_MAX ; - if ( $mysync->{nb_errors} >= $mysync->{errorsmax} ) { - myprint( "Maximum number of errors $mysync->{errorsmax} reached ( you can change $mysync->{errorsmax} to any value, for example 100 with --errorsmax 100 ). Exiting.\n" ) ; - my $most_common_error = errorsanalyse( errors_log( $mysync ) ) ; - if ( $mysync->{errorsdump} ) { - myprint( errorsdump( errors_log( $mysync ) ) ) ; - myprint( "The most frequent error is $most_common_error\n" ) ; - # again since errorsdump( ) can be very verbose and masquerade previous warning - myprint( "Maximum number of errors $mysync->{errorsmax} reached ( you can change $mysync->{errorsmax} to any value, for example 100 with --errorsmax 100 ). Exiting.\n" ) ; - } - my $exit_value = $EXIT_VALUE_OF_ERR_TYPE{ $most_common_error } || $EXIT_CATCH_ALL ; - #exit_clean( $mysync, $EXIT_WITH_ERRORS_MAX ) ; - exit_clean( $mysync, $exit_value ) ; - } - return ; -} sub tests_errors_log { @@ -5790,6 +5886,52 @@ sub errors_log } + +sub tests_comment_of_error_type +{ + note( 'Entering tests_comment_of_error_type()' ) ; + + is( undef, comment_of_error_type( ), 'comment_of_error_type: no args => undef' ) ; + + my $mysync = { } ; + is( undef, comment_of_error_type( $mysync ), 'comment_of_error_type: undef => undef' ) ; + + is( "", comment_of_error_type( $mysync, '' ), 'comment_of_error_type: "" => ""' ) ; + is( "", comment_of_error_type( $mysync, 'blabla' ), 'comment_of_error_type: blabla => ""' ) ; + + is( "", comment_of_error_type( $mysync, 'ERR_UNCLASSIFIED' ), 'comment_of_error_type: ERR_UNCLASSIFIED => ""' ) ; + + like( comment_of_error_type( $mysync, 'ERR_OVERQUOTA' ), qr{100% full}, 'comment_of_error_type: ERR_OVERQUOTA => matches 100% full' ) ; + + + + note( 'Leaving tests_comment_of_error_type()' ) ; + return ; +} + +sub comment_of_error_type +{ + my $mysync = shift @ARG ; + my $error_type = shift @ARG ; + + if ( ! defined $mysync ) { return ; } + if ( ! defined $error_type ) { return ; } + + my $comment ; + + if ( exists( $COMMENT_OF_ERR_TYPE{ $error_type } ) ) + { + $comment = $COMMENT_OF_ERR_TYPE{ $error_type }->( $mysync ) ; + } + else + { + $comment = "" ; + } + return $comment ; +} + + + sub tests_error_type { note( 'Entering tests_error_type()' ) ; @@ -5851,6 +5993,13 @@ sub tests_error_type 'error_type: could not append ... virus => ERR_APPEND_VIRUS' ) ; + + is( 'ERR_FLAGS', + error_type( 'Host2: flags msg INBOX/957910 could not add flags [PasGlop \PasGlopRe]: 33 NO Error in IMAP command received by server.' ), + 'error_type: could not add flags => ERR_FLAGS' + ) ; + + note( 'Leaving tests_error_type()' ) ; return ; } @@ -5902,6 +6051,10 @@ sub error_type # could not append .*NO header limit reached if ( $error =~ m{could not append} ) { return 'ERR_APPEND' ; } ; + # could not add flags + if ( $error =~ m{could not add flags} ) { return 'ERR_FLAGS' ; } ; + + # Could not create folder .*Invalid mailbox name if ( $error =~ m{Could not create folder} ) { return 'ERR_CREATE' ; } ; @@ -5996,6 +6149,7 @@ sub most_common_error if ( !%{ $errors_counted_ref } ) { return 'ERR_NOTHING_REPORTED' ; } # non empty hash + # in case of equality the winner error is the first in alphabetic order my $most_common_error = ( sort { $errors_counted_ref->{$b} <=> $errors_counted_ref->{$a} @@ -6084,17 +6238,69 @@ sub errorsdump sub errors_listing { my $mysync = shift ; - $mysync->{most_common_error} = errorsanalyse( errors_log( $sync ) ) ; + $mysync->{ most_common_error } = errorsanalyse( errors_log( $mysync ) ) ; - my $errors_listing = join( '', - "++++ Listing $mysync->{nb_errors} errors encountered during the sync ( avoid this listing with --noerrorsdump ).\n", - errorsdump( errors_log( $mysync ) ), - "The most frequent error is $mysync->{most_common_error}\n", + my $errors_listing = '' ; + + if ( $mysync->{ errorsdump } ) + { + $errors_listing = join( '', + "++++ Listing $mysync->{nb_errors} errors encountered during the sync ( avoid this listing with --noerrorsdump ).\n", + errorsdump( errors_log( $mysync ) ), + ) ; + } + + $errors_listing .= join( '', + "The most frequent error is $mysync->{ most_common_error }. ", + comment_of_error_type( $mysync, $mysync->{ most_common_error } ), + "\n", ) ; + return $errors_listing ; } +sub errors_incr +{ + my ( $mysync, @error ) = @ARG ; + $mysync->{ nb_errors }++ ; + + if ( @error ) { + errors_log( $mysync, @error ) ; + myprint( @error ) ; + } + + $mysync->{ errorsmax } ||= $ERRORS_MAX ; + + + if ( $mysync->{ nb_errors } >= $mysync->{ errorsmax } ) + { + myprint( errorsmax_msg( $mysync ) ) ; + myprint( errors_listing( $mysync ) ) ; + + if ( $mysync->{ errorsdump } ) + { + # again since errorsdump( ) can be very verbose and masquerade previous warning + myprint( errorsmax_msg( $mysync ) ) ; + } + my $exit_value = exit_value( $mysync, $mysync->{ most_common_error } ) ; + exit_clean( $mysync, $exit_value ) ; + } + return ; +} + + + +sub errorsmax_msg +{ + my $mysync = shift @ARG ; + my $msg = "Maximum number of errors $mysync->{errorsmax} reached " + . "( you can change $mysync->{errorsmax} to any value, for example 100 with --errorsmax 100 ). " + . "Exiting.\n" ; + return $msg ; +} + + sub tests_live_result @@ -6713,17 +6919,21 @@ sub remove_tmp_files sub cleanup_before_exit { my $mysync = shift ; + remove_tmp_files( $mysync ) ; + if ( $mysync->{imap1} and $mysync->{imap1}->IsConnected() ) { myprint( "Disconnecting from host1 $mysync->{ host1 } user1 $mysync->{ user1 }\n" ) ; $mysync->{imap1}->logout( ) ; } + if ( $mysync->{imap2} and $mysync->{imap2}->IsConnected() ) { myprint( "Disconnecting from host2 $mysync->{ host2 } user2 $mysync->{ user2 }\n" ) ; $mysync->{imap2}->logout( ) ; } + if ( $mysync->{log} ) { myprint( "Log file is $mysync->{logfile} ( to change it, use --logfile filepath ; or use --nolog to turn off logging )\n" ) ; } @@ -6736,16 +6946,50 @@ sub cleanup_before_exit #print( "Closing $mysync->{ logfile }\n" ) ; teefinish( $mysync ) ; } + return ; } +sub tests_exit_value +{ + note( 'Entering tests_exit_value()' ) ; + + is( $EXIT_CATCH_ALL, exit_value( ), 'exit_value: no args => EXIT_CATCH_ALL' ) ; + + my $mysync = { } ; + is( $EXIT_CATCH_ALL, exit_value( $mysync ), 'exit_value: undef => EXIT_CATCH_ALL' ) ; + + is( $EXIT_CATCH_ALL, exit_value( $mysync, 'Blabla_unknown' ), 'exit_value: Blabla => EXIT_CATCH_ALL' ) ; + is( $EXIT_CATCH_ALL, exit_value( $mysync, '' ), 'exit_value: empty => EXIT_CATCH_ALL' ) ; + + + is( $EXIT_OVERQUOTA, exit_value( $mysync, 'ERR_OVERQUOTA' ), 'exit_value: ERR_OVERQUOTA => EXIT_OVERQUOTA' ) ; + is( $EXIT_TRANSFER_EXCEEDED, exit_value( $mysync, 'ERR_TRANSFER_EXCEEDED' ), 'exit_value: ERR_TRANSFER_EXCEEDED => EXIT_TRANSFER_EXCEEDED' ) ; + + note( 'Leaving tests_exit_value()' ) ; + return ; +} + +sub exit_value +{ + my $mysync = shift @ARG ; + my $most_common_error = shift @ARG ; + + if ( ! defined $most_common_error ) { return $EXIT_CATCH_ALL ; } + my $exit_value = $EXIT_VALUE_OF_ERR_TYPE{ $most_common_error } || $EXIT_CATCH_ALL ; + + return $exit_value ; +} + + + sub exit_most_errors { my $mysync = shift @ARG ; myprint( errors_listing( $mysync ) ) ; - my $exit_value = $EXIT_VALUE_OF_ERR_TYPE{ $mysync->{most_common_error} } || $EXIT_CATCH_ALL ; + my $exit_value = exit_value( $mysync, $mysync->{ most_common_error } ) ; exit_clean( $mysync, $exit_value ) ; return ; } @@ -7072,8 +7316,9 @@ sub justconnect2 sub skip_macosx { #return ; - # hostname used to be macosx.polarhome.com - return( 'macosx' eq hostname( ) && ( 'darwin' eq $OSNAME ) ) ; + # hostname is sometimes "macosx.polarhome.com" sometimes "macosx" + return( ( ( 'macosx.polarhome.com' eq hostname( ) ) || ( 'macosx' eq hostname( ) ) ) + && ( 'darwin' eq $OSNAME ) ) ; } sub skip_macosx_binary @@ -7140,7 +7385,7 @@ sub tests_mailimapclient_connect is( 1, $imap->Debug( 1 ), 'mailimapclient_connect ipv4 + ssl: setting Debug( 1 )' ) ; # It sounds stupid but it avoids failures on the next test about $imap->connect - is( '2a01:e34:ecde:70d0:223:54ff:fec2:36d7', resolv( 'petiteipv6.lamiral.info' ), 'resolv: petiteipv6.lamiral.info => 2001:41d0:8:bebd::1' ) ; + is( '2a01:e34:ecde:70d0:223:54ff:fec2:36d7', resolv( 'petiteipv6.lamiral.info' ), 'resolv: petiteipv6.lamiral.info => 2a01:e34:ecde:70d0:223:54ff:fec2:36d7' ) ; like( ref( $imap->connect( ) ), qr/IO::Socket::SSL/, 'mailimapclient_connect ipv6 + ssl: connect to petiteipv6.lamiral.info' ) ; # This one is ok on petite, not on ks2, do not know why, so commented. @@ -7340,6 +7585,9 @@ sub connect_imap $imap->Debug( $acc->{ debugimap } ) ; $imap->Timeout( $acc->{ timeout } ) ; + #$imap->Keepalive( $acc->{ keepalive } ) ; + + my $side = lc $acc->{ Side } ; myprint( "$acc->{ Side }: connecting on $side [$host] port [$port]\n" ) ; @@ -7375,7 +7623,145 @@ sub connect_imap return( $imap ) ; } +sub tests_compress_ssl +{ + note( 'Entering tests_compress_ssl()' ) ; + SKIP: { + if ( skip_macosx( ) ) + { + skip( 'Tests avoided on host polarhome macosx, no clue "ssl3_get_server_certificate:certificate verify failed"', 12 ) ; + } + else + { + my $myimap ; + my $acc = {} ; + $acc->{ Side } = 'HostK' ; + $acc->{ authmech } = 'LOGIN' ; + $acc->{ debugimap } = 1 ; + $acc->{ compress } = 1 ; + $acc->{ N } = 'K' ; + + ok( + $myimap = login_imap( 'test1.lamiral.info', 993, 'test1', 'secret1', + 1, undef, + 1, 100, $acc, {}, + ), 'acc_compress_imap: test1.lamiral.info test1 ssl' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'acc_compress_imap: test1.lamiral.info test1 ssl IsAuthenticated' ) ; + + + is( $acc->{ imap }, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info ok" ) ; + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info 2nd nok" ) ; + + ok( + $myimap = login_imap( 'test1.lamiral.info', 143, 'test1', 'secret1', + 0, undef, + 1, 100, $acc, {}, + ), 'acc_compress_imap: test1.lamiral.info test1 tls' ) ; + ok( $myimap && $myimap->IsAuthenticated( ), 'acc_compress_imap: test1.lamiral.info test1 tls IsAuthenticated' ) ; + + is( $acc->{ imap }, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info tls ok" ) ; + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info tls 2nd nok" ) ; + + # Third, no compression + $acc->{ compress } = 0 ; + ok( + $myimap = login_imap( 'test1.lamiral.info', 993, 'test1', 'secret1', + 1, undef, + 1, 100, $acc, {}, + ), 'acc_compress_imap: test1.lamiral.info test1 ssl' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'acc_compress_imap: test1.lamiral.info test1 ssl IsAuthenticated' ) ; + + + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info off ok" ) ; + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info 2nd off ok" ) ; + + } + } + note( 'Leaving tests_compress_ssl()' ) ; + return ; +} + +sub tests_compress +{ + note( 'Entering tests_compress()' ) ; + + my $myimap ; + my $acc = {} ; + $acc->{ Side } = 'HostK' ; + $acc->{ authmech } = 'LOGIN' ; + $acc->{ debugimap } = 1 ; + $acc->{ compress } = 1 ; + $acc->{ N } = 'K' ; + + ok( + $myimap = login_imap( 'test1.lamiral.info', 143, 'test1', 'secret1', + 0, 0, + 1, 100, $acc, {}, + ), 'acc_compress_imap: test1.lamiral.info test1' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'acc_compress_imap: test1.lamiral.info test1 IsAuthenticated' ) ; + + + is( $acc->{ imap }, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info ok" ) ; + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info 2nd nok" ) ; + + ok( + $myimap = login_imap( 'test1.lamiral.info', 143, 'test1', 'secret1', + 0, 0, + 1, 100, $acc, {}, + ), 'acc_compress_imap: test1.lamiral.info test1 tls' ) ; + ok( $myimap && $myimap->IsAuthenticated( ), 'acc_compress_imap: test1.lamiral.info test1 tls IsAuthenticated' ) ; + + is( $acc->{ imap }, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info tls ok" ) ; + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info tls 2nd nok" ) ; + + # Third, no compression + $acc->{ compress } = 0 ; + ok( + $myimap = login_imap( 'test1.lamiral.info', 143, 'test1', 'secret1', + 0, 0, + 1, 100, $acc, {}, + ), 'acc_compress_imap: test1.lamiral.info test1 ssl' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'acc_compress_imap: test1.lamiral.info test1 ssl IsAuthenticated' ) ; + + + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info off ok" ) ; + is( undef, acc_compress_imap( $acc ), "acc_compress_imap: test1.lamiral.info 2nd off ok" ) ; + + note( 'Leaving tests_compress()' ) ; + return ; +} + + +sub acc_compress_imap +{ + my $acc = shift ; + + if ( ! defined( $acc ) ) { return ; } + + my $ret ; + my $imap = $acc->{ imap } ; + if ( ! defined $imap ) { return ; } + + if ( $imap && $acc->{ compress } ) + { + myprint( "$acc->{ Side }: Trying to turn imap compression on. Use --nocompress" . $acc->{ N } . " to avoid compression on " . lc( $acc->{ Side } ) . "\n" ) ; + if ( $ret = $imap->compress() ) + { + myprint( "$acc->{ Side }: Compression is on now\n" ) ; + } + else + { + myprint( "$acc->{ Side }: Failed to turn compression on\n" ) ; + } + } + else + { + myprint( "$acc->{ Side }: Compression is off. Use --compress" . $acc->{ N } . " to allow compression on " . lc( $acc->{ Side } ) . "\n" ) ; + } + # $ret is $acc->{ imap } on success, undef on failure or when there is nothing to do. + return $ret ; +} sub tests_login_imap { @@ -7384,12 +7770,12 @@ sub tests_login_imap is( undef, login_imap( ), 'login_imap: no args => undef' ) ; SKIP: { - if ( skip_macosx_binary( ) ) + if ( skip_macosx( ) ) { - skip( 'Tests avoided only on binary on host polarhome macosx, no clue "ssl3_get_server_certificate:certificate verify failed"', 11 ) ; + skip( 'Tests avoided only on binary on host polarhome macosx, no clue "ssl3_get_server_certificate:certificate verify failed"', 15 ) ; } else{ - + my $myimap ; my $acc = {} ; $acc->{ Side } = 'HostK' ; @@ -7399,8 +7785,14 @@ sub tests_login_imap # echo | openssl s_client -crlf -connect test1.lamiral.info:993 # ... # certificate has expired - # Fix: - # ssh root@test1.lamiral.info 'apt update && apt upgrade && /etc/init.d/dovecot restart' + # Fix: ssh root@test1.lamiral.info 'apt update && apt upgrade && /etc/init.d/dovecot restart' + # + # or + # echo | openssl s_client -crlf -connect test1.lamiral.info:993 + # ... + # Verify return code: 9 (certificate is not yet valid) + # Fix: /etc/init.d/openntpd restart + # 2021_09_04 done ok( $myimap = login_imap( 'test1.lamiral.info', 993, 'test1', 'secret1', 1, undef, @@ -7408,12 +7800,15 @@ sub tests_login_imap ), 'login_imap: test1.lamiral.info test1 ssl' ) ; ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: test1.lamiral.info test1 ssl IsAuthenticated' ) ; + is( $myimap, $acc->{ imap }, "login_imap: acc->{ imap } ok test1 ssl") ; + ok( $myimap = login_imap( 'test1.lamiral.info', 143, 'test1', 'secret1', 0, undef, 1, 100, $acc, {}, ), 'login_imap: test1.lamiral.info test1 tls' ) ; ok( $myimap && $myimap->IsAuthenticated( ), 'login_imap: test1.lamiral.info test1 tls IsAuthenticated' ) ; + is( $myimap, $acc->{ imap }, "login_imap: acc->{ imap } ok test1 tls") ; #$IO::Socket::SSL::DEBUG = 4 ; $acc->{sslargs} = { SSL_version => 'SSLv2' } ; @@ -7425,7 +7820,7 @@ sub tests_login_imap ), 'login_imap: test1.lamiral.info test1 tls SSLv2 not supported' ) ; #SSL_verify_mode => 1 #SSL_version => 'TLSv1_1' - + is( undef, $acc->{ imap }, "login_imap: acc->{ imap } test1 tls error => undef") ; # I have left ? exit_clean to be replaced by errors_incr( $mysync, 'error message' ) @@ -7443,6 +7838,7 @@ sub tests_login_imap ), 'login_imap: noresol.lamiral.info undef' ) ; is( 'ERR_CONNECTION_FAILURE_HOST2', errorsanalyse( errors_log( $mysync ) ), 'login_imap: Host2 noresol.lamiral.info => ERR_CONNECTION_FAILURE_HOST2' ) ; + is( undef, $acc->{ imap }, "login_imap: acc->{ imap } noresol error => undef") ; # authentication failure for user2 $mysync = {} ; @@ -7469,7 +7865,7 @@ sub tests_login_imap } } - + note( 'Leaving tests_login_imap()' ) ; return ; } @@ -7488,7 +7884,7 @@ sub oauthgenerateaccess sub tests_login_imap_oauth { note( 'Entering tests_login_imap_oauth()' ) ; - + oauthgenerateaccess() ; SKIP: { @@ -7552,54 +7948,65 @@ sub tests_login_imap_oauth } } - # oauthdirect authentication success for user1 + # oauthdirect authentication success for user1 SKIP: { - if ( ! -r 'oauth2/D_oauth2_oauthdirect_imapsync.gl0@gmail.com.txt' ) + if ( ! -r 'oauth2/D_oauth2_oauthdirect_imapsync.gl0@gmail.com.txt' ) { - skip( 'oauthdirect: no oauthdirect file', 2 ) ; + skip( 'oauthdirect: no oauthdirect file', 6 ) ; } my $myimap ; - my $mysync = {} ; - my $acc = {} ; - $acc->{ Side } = 'Host1' ; - $acc->{ oauthdirect } = 'oauth2/D_oauth2_oauthdirect_imapsync.gl0@gmail.com.txt' ; - $acc->{ debugimap } = 1 ; - $mysync->{ showpasswords } = 1 ; - $acc->{ authmech } = 'QQQ' ; - isa_ok( - $myimap = login_imap( 'imap.gmail.com', 993, 'user_useless', 'password_useless', - 1, undef, - 1, 100, $acc, $mysync, - ), 'Mail::IMAPClient', 'login_imap: user1 good oauthdirect => Mail::IMAPClient' ) ; + my $mysync = {} ; + my $acc = {} ; + $acc->{ Side } = 'Host1' ; + $acc->{ oauthdirect } = 'oauth2/D_oauth2_oauthdirect_imapsync.gl0@gmail.com.txt' ; + $acc->{ debugimap } = 1 ; + $mysync->{ showpasswords } = 1 ; + $acc->{ authmech } = 'QQQ' ; + isa_ok( + $myimap = login_imap( 'imap.gmail.com', 993, 'user_useless', 'password_useless', + 1, undef, + 1, 100, $acc, $mysync, + ), 'Mail::IMAPClient', 'login_imap: user1 good oauthdirect => Mail::IMAPClient' ) ; - ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 IsAuthenticated' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthdirect IsAuthenticated' ) ; + + ok( defined( $myimap ) && $myimap->logout( ), 'login_imap: gmail oauth2 oauthdirect logout' ) ; + ok( defined( $myimap ) && ! $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthdirect not IsAuthenticated after logout' ) ; + ok( defined( $myimap ) && $myimap->reconnect( ), 'login_imap: gmail oauth2 oauthdirect reconnect ok' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthdirect IsAuthenticated after reconnect' ) ; } - - # oauthaccesstoken authentication success for user1 + + + + # oauthaccesstoken authentication success for user1 SKIP: { - if ( ! -r 'oauth2/D_oauth2_access_token_imapsync.gl0@gmail.com.txt' ) + if ( ! -r 'oauth2/D_oauth2_access_token_imapsync.gl0@gmail.com.txt' ) { - skip( 'oauthaccesstoken: no access_token file', 2 ) ; + skip( 'oauthaccesstoken: no access_token file', 6 ) ; } my $myimap ; - my $mysync = {} ; - my $acc = {} ; - $acc->{ Side } = 'Host1' ; - $acc->{ oauthaccesstoken } = 'oauth2/D_oauth2_access_token_imapsync.gl0@gmail.com.txt' ; - $acc->{ debugimap } = 1 ; - $mysync->{ showpasswords } = 1 ; - $acc->{ authmech } = 'QQQ' ; - isa_ok( - $myimap = login_imap( 'imap.gmail.com', 993, 'imapsync.gl0@gmail.com', 'password_useless', - 1, undef, - 1, 100, $acc, $mysync, - ), 'Mail::IMAPClient', 'login_imap: user1 good oauthaccesstoken => Mail::IMAPClient' ) ; + my $mysync = {} ; + my $acc = {} ; + $acc->{ Side } = 'Host1' ; + $acc->{ oauthaccesstoken } = 'oauth2/D_oauth2_access_token_imapsync.gl0@gmail.com.txt' ; + $acc->{ debugimap } = 1 ; + $mysync->{ showpasswords } = 1 ; + $acc->{ authmech } = 'QQQ' ; + isa_ok( + $myimap = login_imap( 'imap.gmail.com', 993, 'imapsync.gl0@gmail.com', 'password_useless', + 1, undef, + 1, 100, $acc, $mysync, + ), 'Mail::IMAPClient', 'login_imap: user1 good oauthaccesstoken => Mail::IMAPClient' ) ; - ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthaccesstoken IsAuthenticated' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthaccesstoken IsAuthenticated' ) ; + ok( defined( $myimap ) && $myimap->logout( ), 'login_imap: gmail oauth2 oauthaccesstoken logout' ) ; + ok( defined( $myimap ) && ! $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthaccesstoken not IsAuthenticated after logout' ) ; + ok( defined( $myimap ) && $myimap->reconnect( ), 'login_imap: gmail oauth2 oauthaccesstoken reconnect ok' ) ; + ok( defined( $myimap ) && $myimap->IsAuthenticated( ), 'login_imap: gmail oauth2 oauthaccesstoken IsAuthenticated after reconnect' ) ; } - - + + note( 'Leaving tests_login_imap_oauth()' ) ; return ; } @@ -7614,6 +8021,8 @@ sub login_imap $ssl, $tls, $uid, $split, $acc, $mysync ) = @allargs ; + $acc->{ imap } = undef ; + if ( ! all_defined( $host, $port, $user, $acc->{ Side } ) ) { return ; @@ -7676,6 +8085,7 @@ sub login_imap if ( authenticate_imap( $imap, @allargs ) ) { myprint( "$acc->{ Side }: success login on [$host] with user [$user] auth [$acc->{ authmech }] or [LOGIN]\n" ) ; + $acc->{ imap } = $imap ; return( $imap ) ; } else @@ -7715,19 +8125,27 @@ sub init_imap $imap->Buffer( $buffersize || $DEFAULT_BUFFER_SIZE ) ; $imap->Uid( $uid ) ; - $imap->Peek( 1 ) ; $imap->Debug( $acc->{ debugimap } ) ; if ( $mysync->{ showpasswords } ) { $imap->Showcredentials( 1 ) ; } - defined $acc->{ timeout } and $imap->Timeout( $acc->{ timeout } ) ; + if ( defined( $acc->{ timeout } ) ) + { + $imap->Timeout( $acc->{ timeout } ) ; + } + + if ( defined $acc->{ keepalive } ) + { + $imap->Keepalive( $acc->{ keepalive } ) ; + } if ( defined $acc->{ reconnectretry } ) { $imap->Reconnectretry( $acc->{ reconnectretry } ) ; } + $imap->{IMAPSYNC_RECONNECT_COUNT} = 0 ; $imap->Ignoresizeerrors( $allowsizemismatch ) ; $split and $imap->Maxcommandlength( $SPLIT_FACTOR * $split ) ; @@ -7768,15 +8186,15 @@ sub authenticate_imap $acc->{ authmech } = 'XOAUTH2 direct' ; return( oauthdirect( $mysync, $acc, $imap, $host, $user ) ) ; } - - + + if ( defined $acc->{ oauthaccesstoken } ) { $acc->{ authmech } = 'XOAUTH2 accesstoken' ; return( oauthaccesstoken( $mysync, $acc, $imap, $host, $user ) ) ; } - - + + if ( $acc->{ proxyauth } ) { @@ -7877,7 +8295,12 @@ sub oauthdirect { $oauthdirect_str = $acc->{ oauthdirect } || 'Please define oauthdirect value' ; } - if ( $imap->authenticate('XOAUTH2', sub { return $oauthdirect_str } ) ) + + $imap->Authmechanism( 'XOAUTH2' ) ; + $imap->Authcallback( sub { return $oauthdirect_str } ) ; + + #if ( $imap->authenticate('XOAUTH2', sub { return $oauthdirect_str } ) ) + if ( $imap->login( ) ) { return 1 ; } @@ -7905,7 +8328,7 @@ sub oauthaccesstoken { $oauthaccesstoken_str = $acc->{ oauthaccesstoken } || 'Please define oauthaccesstoken value' ; } - + my $oauth_string = "user=" . $user . "\x01auth=Bearer ". $oauthaccesstoken_str . "\x01\x01" ; #myprint "oauth_string: $oauth_string\n" ; @@ -7913,8 +8336,12 @@ sub oauthaccesstoken #myprint "oauth_string_base64: $oauth_string_base64\n" ; my $oauthdirect_str = $oauth_string_base64 ; - - if ( $imap->authenticate('XOAUTH2', sub { return $oauthdirect_str } ) ) + + $imap->Authmechanism( 'XOAUTH2' ) ; + $imap->Authcallback( sub { return $oauthdirect_str } ) ; + + #if ( $imap->authenticate('XOAUTH2', sub { return $oauthdirect_str } ) ) + if ( $imap->login( ) ) { return 1 ; } @@ -8027,7 +8454,7 @@ sub plainauth my $imap = shift; my $string = mysprintf("%s\x00%s\x00%s", $imap->User, - $imap->Authuser, $imap->Password); + defined $imap->Authuser ? $imap->Authuser : "", $imap->Password); return encode_base64("$string", q{}); } @@ -8203,6 +8630,38 @@ sub xmasterauth return ; } +sub keepalive1 +{ + my $mysync = shift ; + + $mysync->{ acc1 }->{ keepalive } = defined $mysync->{ acc1 }->{ keepalive } ? $mysync->{ acc1 }->{ keepalive } : 1 ; + + if ( $mysync->{ acc1 }->{ keepalive } ) + { + myprint( "Host1: imap connection keepalive is on on host1. Use --nokeepalive1 to disable it.\n" ) ; + } + else + { + myprint( "Host1: imap connection keepalive is off on host1. Use --keepalive1 to enable it.\n" ) ; + } +} + +sub keepalive2 +{ + my $mysync = shift ; + + $mysync->{ acc2 }->{ keepalive } = defined $mysync->{ acc2 }->{ keepalive } ? $mysync->{ acc2 }->{ keepalive } : 1 ; + + if ( $mysync->{ acc2 }->{ keepalive } ) + { + myprint( "Host2: imap connection keepalive is on on host2. Use --nokeepalive2 to disable it.\n" ) ; + } + else + { + myprint( "Host2: imap connection keepalive is off on host2. Use --keepalive2 to enable it.\n" ) ; + } +} + sub banner_imapsync @@ -8212,8 +8671,8 @@ sub banner_imapsync my $banner_imapsync = join q{}, q{$RCSfile: imapsync,v $ }, - q{$Revision: 2.148 $ }, - q{$Date: 2021/07/22 14:21:09 $ }, + q{$Revision: 2.178 $ }, + q{$Date: 2022/01/12 21:28:37 $ }, "\n", "Command line used, run by $EXECUTABLE_NAME:\n", "$PROGRAM_NAME ", command_line_nopassword( $mysync, @argv ), "\n" ; @@ -8342,16 +8801,16 @@ sub remove_pidfile_not_running { # my $pid_filename = shift @ARG ; - + #myprint( "In remove_pidfile_not_running $pid_filename\n" ) ; if ( ! $pid_filename ) { myprint( "No variable pid_filename\n" ) ; return } ; if ( ! -e $pid_filename ) - { + { myprint( "File $pid_filename does not exist\n" ) ; return ; } #myprint( "Still In remove_pidfile_not_running $pid_filename\n" ) ; - + if ( ! -f $pid_filename ) { myprint( "File $pid_filename is not a file\n" ) ; return } ; my $pid = firstline( $pid_filename ) ; @@ -8437,7 +8896,7 @@ sub tail if ( ! $tail ) { return ; } if ( ! -e $pidfile ) { return ; } - + my $pidtotail = firstline( $pidfile ) ; if ( ! $pidtotail ) { return ; } @@ -8550,7 +9009,7 @@ sub write_pidfile { # returns undef if something is considered fatal # returns 1 otherwise - + #myprint( "In write_pidfile\n" ) ; if ( ! @ARG ) { return 1 ; } @@ -8912,6 +9371,7 @@ sub create_folder return( create_folder_old( $mysync, $myimap2 , $h2_fold , $h1_fold ) ) ; } + # $imap->exists() calls $imap->status() that does an IMAP STATUS folder myprint( "Creating folder [$h2_fold] on host2\n" ) ; if ( ( 'INBOX' eq uc $h2_fold ) and ( $myimap2->exists( $h2_fold ) ) ) { @@ -8944,9 +9404,12 @@ sub create_folder "Could not create folder [$h2_fold] from [$h1_fold]: " , $myimap2->LastError( ), "\n" ; errors_incr( $mysync, $error ) ; - # success if folder exists ("already exists" error) - return( 1 ) if $myimap2->exists( $h2_fold ) ; - # failure since create failed + # success if folder exists ("already exists" error) or selectable + if ( $myimap2->exists( $h2_fold ) or select_folder( $mysync, $myimap2, $h2_fold, 'Host2' ) ) + { + return( 1 ) ; + } + # failure since create failed + not exist + not selectable return( 0 ) ; }else{ #create succeeded @@ -10119,8 +10582,8 @@ sub tests_regexflags { note( 'Entering tests_regexflags()' ) ; - my $mysync = {} ; - + my $mysync = {} ; + ok( q{} eq regexflags( $mysync, q{} ), 'regexflags, null string q{}' ) ; ok( q{\Seen NonJunk $Spam} eq regexflags( $mysync, q{\Seen NonJunk $Spam} ), q{regexflags, nothing to do} ) ; @@ -10214,14 +10677,14 @@ sub tests_regexflags $mysync->{ regexflag } = [ ] ; $mysync->{ filterbuggyflags } = 1 ; filterbuggyflags( $mysync ) ; - + is( '\Deleted \Answered \Draft \Flagged', regexflags( $mysync, '\\Deleted \\Answered \\RECEIPTCHECKED \\Draft \\Indexed \\Flagged' ), 'regexflags: remove famous /X 1' ) ; is( '\\Deleted \\Flagged \\Answered \\Draft', regexflags( $mysync, '\\Deleted \\RECEIPTCHECKED \\Flagged \\Answered \\Indexed \\Draft' ), - 'regexflags: remove famous /X 2' ) ; + 'regexflags: remove famous /X 2' ) ; is( '\ ', '\\ ', 'regexflags: \ is \\ ' ) ; is( '\\ ', '\\ ', 'regexflags: \\ is \\ ' ) ; @@ -10234,7 +10697,7 @@ sub regexflags { my $mysync = shift ; my $flags = shift ; - + foreach my $regexflag ( @{ $mysync->{ regexflag } } ) { my $flags_orig = $flags ; @@ -10347,18 +10810,21 @@ sub tests_permanentflags { note( 'Entering tests_permanentflags()' ) ; - my $string; - ok(q{} eq permanentflags(' * OK [PERMANENTFLAGS (\* \Draft \Answered)] Limited'), - 'permanentflags \*'); - ok('\Draft \Answered' eq permanentflags(' * OK [PERMANENTFLAGS (\Draft \Answered)] Limited'), - 'permanentflags \Draft \Answered'); - ok('\Draft \Answered' - eq permanentflags('Blabla', + my $mysync = { } ; + ok( q{} eq permanentflags( $mysync, ' * OK [PERMANENTFLAGS (\* \Draft \Answered)] Limited' ), + 'permanentflags \*' ) ; + + ok( '\Draft \Answered' eq permanentflags( $mysync, ' * OK [PERMANENTFLAGS (\Draft \Answered)] Limited' ), + 'permanentflags \Draft \Answered' ) ; + + ok( '\Draft \Answered' + eq permanentflags( $mysync, 'Blabla', ' * OK [PERMANENTFLAGS (\Draft \Answered)] Limited', - 'Blabla'), + 'Blabla' ), 'permanentflags \Draft \Answered' - ); - ok(q{} eq permanentflags('Blabla'), 'permanentflags nothing'); + ) ; + + ok( q{} eq permanentflags( $mysync, 'Blabla' ), 'permanentflags nothing' ) ; note( 'Leaving tests_permanentflags()' ) ; return ; @@ -10366,7 +10832,9 @@ sub tests_permanentflags sub permanentflags { - my @lines = @_ ; + my $mysync = shift ; + + my @lines = @_ ; foreach my $line (@lines) { if ( $line =~ m{\[PERMANENTFLAGS\s\(([^)]+?)\)\]}x ) { @@ -10449,37 +10917,37 @@ sub tests_flags_for_host2 note( 'Entering tests_flags_for_host2()' ) ; is( undef, flags_for_host2( ), 'flags_for_host2: no args => undef' ) ; - + my $mysync ; is( undef, flags_for_host2( $mysync ), 'flags_for_host2: undef => undef' ) ; - + $mysync = { } ; is( undef, flags_for_host2( $mysync ), 'flags_for_host2: nothing => undef' ) ; - + is( q{}, flags_for_host2( $mysync, '' ), 'flags_for_host2: no flags => empty string' ) ; - + is( q{}, flags_for_host2( $mysync, '\Recent' ), 'flags_for_host2: \Recent => empty string' ) ; - + is( q{\Seen}, flags_for_host2( $mysync, '\Recent \Seen' ), 'flags_for_host2: \Recent \Seen => \Seen' ) ; - + is( q{\Deleted \Seen}, flags_for_host2( $mysync, '\Deleted \Recent \Seen' ), 'flags_for_host2: \Deleted \Recent \Seen => \Deleted \Seen' ) ; - + $mysync->{ flagscase } = 0 ; is( q{\DELETED \Seen}, flags_for_host2( $mysync, '\DELETED \Seen' ), 'flags_for_host2: flagscase = 0 \DELETED \Seen => \DELETED \Seen' ) ; - + $mysync->{ flagscase } = 1 ; is( q{\Deleted \Seen}, flags_for_host2( $mysync, '\DELETED \Seen' ), 'flags_for_host2: flagscase = 1 \DELETED \Seen => \Deleted \Seen' ) ; - + $mysync->{ filterflags } = 0 ; is( q{\Seen \Blabla}, flags_for_host2( $mysync, '\Seen \Blabla', '\Seen \Junk' ), 'flags_for_host2: filterflags = 0 \Seen \Blabla among \Seen \Junk => \Seen \Blabla' ) ; - + $mysync->{ filterflags } = 1 ; is( q{\Seen}, flags_for_host2( $mysync, '\Seen \Blabla', '\Seen \Junk' ), 'flags_for_host2: filterflags = 1 \Seen \Blabla among \Seen \Junk => \Seen' ) ; - + $mysync->{ filterflags } = 1 ; is( q{\Seen \Blabla}, flags_for_host2( $mysync, '\Seen \Blabla', '' ), 'flags_for_host2: filterflags = 1 \Seen \Blabla among "" => \Seen \Blabla' ) ; - - + + note( 'Leaving tests_flags_for_host2()' ) ; return ; } @@ -10492,27 +10960,27 @@ sub flags_for_host2 my $mysync = shift ; my $h1_flags = shift ; my $permanentflags2 = shift ; - - if ( ! all_defined( $mysync, $h1_flags ) ) { return ; } ; - + + if ( ! all_defined( $mysync, $h1_flags ) ) { return ; } ; + # RFC 2060: This flag can not be altered by any client $h1_flags =~ s@\\Recent\s?@@xgi ; - + my $h1_flags_re ; if ( $mysync->{ regexflag } and defined( $h1_flags_re = regexflags( $mysync, $h1_flags ) ) ) { $h1_flags = $h1_flags_re ; } - + if ( $mysync->{ flagscase } ) { $h1_flags = flagscase( $h1_flags ) ; } - + if ( $permanentflags2 and $mysync->{ filterflags } ) { $h1_flags = flags_filter( $h1_flags, $permanentflags2 ) ; } - + return( $h1_flags ) ; } @@ -11052,17 +11520,59 @@ sub message_for_host2 $string_len = length_ref( $string_ref ) ; - $debugcontent and myprint( - q{=} x $STD_CHAR_PER_LINE, "\n", - "F message content begin next line ($string_len characters long)\n", - ${ $string_ref }, - "\nF message content ended on previous line\n", q{=} x $STD_CHAR_PER_LINE, "\n" ) ; + $mysync->{ debugcontent } and myprint( debugcontent( $mysync, $string_ref ) ) ; myprint( debugmemory( $mysync, " at M3" ) ) ; return $string_len ; } +sub tests_debugcontent +{ + note( 'Entering tests_debugcontent()' ) ; + + is( undef, debugcontent( ), 'debugcontent: no args => undef' ) ; + my $mysync = { } ; + is( undef, debugcontent( $mysync ), 'debugcontent: undef => undef' ) ; + is( undef, debugcontent( $mysync, 'mm' ), 'debugcontent: undef, mm => undef' ) ; + #my $string_ref = \'zztop' ; + my $string = '================================================================================ +F message content begin next line (2 characters long) +mm +F message content ended on previous line +================================================================================ +' ; + is( $string, debugcontent( $mysync, \'mm' ), 'debugcontent: undef, mm => mm' ) ; + + note( 'Leaving tests_debugcontent()' ) ; + return ; +} + +sub debugcontent +{ + my $mysync = shift @ARG ; + if ( ! defined $mysync ) { return ; } + + my $string_ref = shift @ARG ; + if ( ! defined $string_ref ) { return ; } + if ( 'SCALAR' ne ref( $string_ref ) ) { return ; } + + my $string_len = length_ref( $string_ref ) ; + + my $string = join( '', + q{=} x $STD_CHAR_PER_LINE, "\n", + "F message content begin next line ($string_len characters long)\n", + ${ $string_ref }, + "\nF message content ended on previous line\n", q{=} x $STD_CHAR_PER_LINE, "\n", + ) ; + + return $string ; +} + + + + + sub tests_truncmess { note( 'Entering tests_truncmess()' ) ; @@ -11809,9 +12319,9 @@ sub append_message_on_host2 $mysync->{ biggest_message_transferred } = max( $string_len, $mysync->{ biggest_message_transferred } ) ; my $time_spent = timesince( $mysync->{begin_transfer_time} ) ; - my $rate = bytes_display_string( $mysync->{total_bytes_transferred} / $time_spent ) ; + my $rate = bytes_display_string_bin( $mysync->{total_bytes_transferred} / $time_spent ) ; my $eta = eta( $mysync ) ; - my $amount_transferred = bytes_display_string( $mysync->{total_bytes_transferred} ) ; + my $amount_transferred = bytes_display_string_bin( $mysync->{total_bytes_transferred} ) ; myprintf( "msg %s/%-19s copied to %s/%-10s %.2f msgs/s %s/s %s copied %s\n", $h1_fold, "$h1_msg {$string_len}", $h2_fold, $new_id, $mysync->{nb_msg_transferred}/$time_spent, $rate, $amount_transferred, @@ -14052,42 +14562,72 @@ sub skipmess -sub tests_bytes_display_string +sub tests_bytes_display_string_bin { - note( 'Entering tests_bytes_display_string()' ) ; + note( 'Entering tests_bytes_display_string_bin()' ) ; + + is( 'NA', bytes_display_string_bin( ), 'bytes_display_string_bin: no args => NA' ) ; + is( 'NA', bytes_display_string_bin( undef ), 'bytes_display_string_bin: undef => NA' ) ; + is( 'NA', bytes_display_string_bin( 'blabla' ), 'bytes_display_string_bin: blabla => NA' ) ; + + is( '0.000 KiB', bytes_display_string_bin( 0 ), 'bytes_display_string_bin: 0 => 0.000 KiB' ) ; + is( '0.001 KiB', bytes_display_string_bin( 1 ), 'bytes_display_string_bin: 1 => 0.001 KiB' ) ; + is( '0.010 KiB', bytes_display_string_bin( 10 ), 'bytes_display_string_bin: 10 => 0.010 KiB' ) ; + is( '0.976 KiB', bytes_display_string_bin( 999 ), 'bytes_display_string_bin: 999 => 0.976 KiB' ) ; + note( bytes_display_string_bin( 999 ) ) ; + + is( '0.999 KiB', bytes_display_string_bin( 1023 ), 'bytes_display_string_bin: 1023 => 0.999 KiB' ) ; + note( bytes_display_string_bin( 1023 ) ) ; + is( '1.000 KiB', bytes_display_string_bin( 1024 ), 'bytes_display_string_bin: 1024 => 1.000 KiB' ) ; + note( bytes_display_string_bin( 1024 ) ) ; + is( '1.001 KiB', bytes_display_string_bin( 1025 ), 'bytes_display_string_bin: 1025 => 1.001 KiB' ) ; + + is( '9.999 KiB', bytes_display_string_bin( 10_239 ), 'bytes_display_string_bin: 10_239 => 9.999 KiB' ) ; + note( bytes_display_string_bin( 10_239 ) ) ; + + is( '10.000 KiB', bytes_display_string_bin( 10_240 ), 'bytes_display_string_bin: 10_240 => 10.000 KiB' ) ; + note( bytes_display_string_bin( 10_240 ) ) ; + + is( '999.999 KiB', bytes_display_string_bin( 1_023_999 ), 'bytes_display_string_bin: 1_023_999 => 999.999 KiB' ) ; + note( bytes_display_string_bin( 1_023_999 ) ) ; + + is( '0.977 MiB', bytes_display_string_bin( 1_024_000 ), 'bytes_display_string_bin: 1_024_000 => 0.977 MiB' ) ; + note( bytes_display_string_bin( 1_024_000 ) ) ; + + is( '0.999 MiB', bytes_display_string_bin( 1_047_527 ), 'bytes_display_string_bin: 1_047_527 => 0.999 MiB' ) ; + note( bytes_display_string_bin( 1_047_527 ) ) ; + + is( '0.999 MiB', bytes_display_string_bin( 1_048_051 ), 'bytes_display_string_bin: 1_048_051 => 0.999 MiB' ) ; + note( bytes_display_string_bin( 1_048_051 ) ) ; + + is( '1.000 MiB', bytes_display_string_bin( 1_048_052 ), 'bytes_display_string_bin: 1_048_052 => 1.000 MiB' ) ; + note( bytes_display_string_bin( 1_048_052 ) ) ; + + is( '1.000 MiB', bytes_display_string_bin( 1_048_575 ), 'bytes_display_string_bin: 1_048_575 => 1.000 MiB' ) ; + is( '1.000 MiB', bytes_display_string_bin( 1_048_576 ), 'bytes_display_string_bin: 1_048_576 => 1.000 MiB' ) ; + + is( '1.000 GiB', bytes_display_string_bin( 1_073_741_823 ), 'bytes_display_string_bin: 1_073_741_823 => 1.000 GiB' ) ; + is( '1.000 GiB', bytes_display_string_bin( 1_073_741_824 ), 'bytes_display_string_bin: 1_073_741_824 => 1.000 GiB' ) ; - is( 'NA', bytes_display_string( ), 'bytes_display_string: no args => NA' ) ; - is( 'NA', bytes_display_string( undef ), 'bytes_display_string: undef => NA' ) ; - is( 'NA', bytes_display_string( 'blabla' ), 'bytes_display_string: blabla => NA' ) ; + is( '1.000 TiB', bytes_display_string_bin( 1_099_511_627_775 ), 'bytes_display_string_bin: 1_099_511_627_775 => 1.000 TiB' ) ; + is( '1.000 TiB', bytes_display_string_bin( 1_099_511_627_776 ), 'bytes_display_string_bin: 1_099_511_627_776 => 1.000 TiB' ) ; - is( '0.000 KiB', bytes_display_string( 0 ), 'bytes_display_string: 0' ) ; - is( '0.001 KiB', bytes_display_string( 1 ), 'bytes_display_string: 1' ) ; - is( '0.010 KiB', bytes_display_string( 10 ), 'bytes_display_string: 10' ) ; - is( '1.000 MiB', bytes_display_string( 1_048_575 ), 'bytes_display_string: 1_048_575' ) ; - is( '1.000 MiB', bytes_display_string( 1_048_576 ), 'bytes_display_string: 1_048_576' ) ; + is( '1.000 PiB', bytes_display_string_bin( 1_125_899_906_842_623 ), 'bytes_display_string_bin: 1_125_899_906_842_623 => 1.000 PiB' ) ; + is( '1.000 PiB', bytes_display_string_bin( 1_125_899_906_842_624 ), 'bytes_display_string_bin: 1_125_899_906_842_624 => 1.000 PiB' ) ; - is( '1.000 GiB', bytes_display_string( 1_073_741_823 ), 'bytes_display_string: 1_073_741_823 ' ) ; - is( '1.000 GiB', bytes_display_string( 1_073_741_824 ), 'bytes_display_string: 1_073_741_824 ' ) ; + is( '1024.000 PiB', bytes_display_string_bin( 1_152_921_504_606_846_975 ), 'bytes_display_string_bin: 1_152_921_504_606_846_975 => 1024.000 PiB' ) ; + is( '1024.000 PiB', bytes_display_string_bin( 1_152_921_504_606_846_976 ), 'bytes_display_string_bin: 1_152_921_504_606_846_976 => 1024.000 PiB' ) ; - is( '1.000 TiB', bytes_display_string( 1_099_511_627_775 ), 'bytes_display_string: 1_099_511_627_775' ) ; - is( '1.000 TiB', bytes_display_string( 1_099_511_627_776 ), 'bytes_display_string: 1_099_511_627_776' ) ; - - is( '1.000 PiB', bytes_display_string( 1_125_899_906_842_623 ), 'bytes_display_string: 1_125_899_906_842_623' ) ; - is( '1.000 PiB', bytes_display_string( 1_125_899_906_842_624 ), 'bytes_display_string: 1_125_899_906_842_624' ) ; - - is( '1024.000 PiB', bytes_display_string( 1_152_921_504_606_846_975 ), 'bytes_display_string: 1_152_921_504_606_846_975' ) ; - is( '1024.000 PiB', bytes_display_string( 1_152_921_504_606_846_976 ), 'bytes_display_string: 1_152_921_504_606_846_976' ) ; - - is( '1048576.000 PiB', bytes_display_string( 1_180_591_620_717_411_303_424 ), 'bytes_display_string: 1_180_591_620_717_411_303_424' ) ; - - #myprint( bytes_display_string( 1_180_591_620_717_411_303_424 ), "\n" ) ; - note( 'Leaving tests_bytes_display_string()' ) ; + is( '1048576.000 PiB', bytes_display_string_bin( 1_180_591_620_717_411_303_424 ), 'bytes_display_string_bin: 1_180_591_620_717_411_303_424 => 1048576.000 PiB' ) ; + note( bytes_display_string_bin( 1_180_591_620_717_411_303_424 ) ) ; + note( bytes_display_string_bin( 3_000_000_000 ) ) ; + note( 'Leaving tests_bytes_display_string_bin()' ) ; return ; } -sub bytes_display_string +sub bytes_display_string_bin { my ( $bytes ) = @_ ; @@ -14128,6 +14668,95 @@ sub bytes_display_string return( $readable_value ) ; } +sub tests_bytes_display_string_dec +{ + note( 'Entering tests_bytes_display_string_dec()' ) ; + + is( 'NA', bytes_display_string_dec( ), 'bytes_display_string_dec: no args => NA' ) ; + is( 'NA', bytes_display_string_dec( undef ), 'bytes_display_string_dec: undef => NA' ) ; + is( 'NA', bytes_display_string_dec( 'blabla' ), 'bytes_display_string_dec: blabla => NA' ) ; + + is( '0 bytes', bytes_display_string_dec( 0 ), 'bytes_display_string_dec: 0 => 0 bytes' ) ; + is( '1 bytes', bytes_display_string_dec( 1 ), 'bytes_display_string_dec: 1 => 1 bytes' ) ; + is( '10 bytes', bytes_display_string_dec( 10 ), 'bytes_display_string_dec: 10 => 10 bytes' ) ; + is( '999 bytes', bytes_display_string_dec( 999 ), 'bytes_display_string_dec: 999 => 999 bytes' ) ; + + is( '1.000 KB', bytes_display_string_dec( 1000 ), 'bytes_display_string_dec: 1000 => 1.000 KB' ) ; + is( '1.001 KB', bytes_display_string_dec( 1001 ), 'bytes_display_string_dec: 1000 => 1.1001 KB' ) ; + + is( '999.999 KB', bytes_display_string_dec( 999_999 ), 'bytes_display_string_dec: 999_999 => 999.999 KB' ) ; + + is( '1.000 MB', bytes_display_string_dec( 1_000_000 ), 'bytes_display_string_dec: 1_000_000 => 1.000 MB' ) ; + is( '1.000 MB', bytes_display_string_dec( 1_000_500 ), 'bytes_display_string_dec: 1_000_500 => 1.000 MB' ) ; + is( '1.001 MB', bytes_display_string_dec( 1_000_501 ), 'bytes_display_string_dec: 1_000_501 => 1.001 MB' ) ; + is( '999.999 MB', bytes_display_string_dec( 999_999_000 ), 'bytes_display_string_dec: 999_999_000 => 999.999 MB' ) ; + is( '999.999 MB', bytes_display_string_dec( 999_999_499 ), 'bytes_display_string_dec: 999_999_499 => 999.999 MB' ) ; + is( '1.000 GB', bytes_display_string_dec( 999_999_500 ), 'bytes_display_string_dec: 999_999_500 => 1.000 GB' ) ; + + is( '1.000 GB', bytes_display_string_dec( 1_000_000_000 ), 'bytes_display_string_dec: 1_000_000_000 => 1.000 GB' ) ; + is( '1.000 GB', bytes_display_string_dec( 1_000_500_000 ), 'bytes_display_string_dec: 1_000_500_000 => 1.000 GB' ) ; + is( '1.001 GB', bytes_display_string_dec( 1_000_500_001 ), 'bytes_display_string_dec: 1_000_501_000 => 1.001 GB' ) ; + is( '999.999 GB', bytes_display_string_dec( 999_999_000_000 ), 'bytes_display_string_dec: 999_999_000_000 => 999.999 GB' ) ; + is( '999.999 GB', bytes_display_string_dec( 999_999_499_999 ), 'bytes_display_string_dec: 999_999_499_999 => 999.999 GB' ) ; + is( '1.000 TB', bytes_display_string_dec( 999_999_500_000 ), 'bytes_display_string_dec: 999_999_500_000 => 1.000 TB' ) ; + + is( '1.000 TB', bytes_display_string_dec( 1_000_000_000_000 ), 'bytes_display_string_dec: 1_000_000_000_000 => 1.000 TB' ) ; + is( '1.000 TB', bytes_display_string_dec( 1_000_500_000_000 ), 'bytes_display_string_dec: 1_000_500_000_000 => 1.000 TB' ) ; + is( '1.001 TB', bytes_display_string_dec( 1_000_500_000_001 ), 'bytes_display_string_dec: 1_000_500_000_000 => 1.000 TB' ) ; + is( '999.999 TB', bytes_display_string_dec( 999_999_000_000_000 ), 'bytes_display_string_dec: 999_999_000_000_000 => 999.999 TB' ) ; + is( '999.999 TB', bytes_display_string_dec( 999_999_499_999_999 ), 'bytes_display_string_dec: 999_999_499_999_999 => 999.999 TB' ) ; + is( '1.000 PB', bytes_display_string_dec( 999_999_500_000_000 ), 'bytes_display_string_dec: 999_999_500_000_000 => 1.000 PB' ) ; + + is( '3.000 GB', bytes_display_string_dec( 3_000_000_000 ), 'bytes_display_string_dec: 3_000_000_000 => 3.000 GB' ) ; + + note( 'Leaving tests_bytes_display_string_dec()' ) ; + return ; +} + +sub bytes_display_string_dec +{ + my ( $bytes ) = @_ ; + + my $readable_value = q{} ; + + if ( ! defined( $bytes ) ) { + return( 'NA' ) ; + } + + if ( not match_number( $bytes ) ) { + return( 'NA' ) ; + } + + SWITCH: { + if ( abs( $bytes ) < ( 1000 ) ) { + $readable_value = mysprintf( '%.0f bytes', $bytes ) ; + last SWITCH ; + } + if ( abs( $bytes ) < ( 1000**2 ) ) { + $readable_value = mysprintf( '%.3f KB', $bytes / 1000 ) ; + last SWITCH ; + } + if ( abs( $bytes ) < ( 999_999_500 ) ) { + $readable_value = mysprintf( '%.3f MB', $bytes / ( 1000**2 ) ) ; + last SWITCH ; + } + if ( abs( $bytes ) < ( 999_999_500_000 ) ) { + $readable_value = mysprintf( '%.3f GB', $bytes / ( 1000**3 ) ) ; + last SWITCH ; + } + if ( abs( $bytes ) < ( 999_999_500_000_000 ) ) { + $readable_value = mysprintf( '%.3f TB', $bytes / ( 1000**4 ) ) ; + last SWITCH ; + } else { + $readable_value = mysprintf( '%.3f PB', $bytes / ( 1000**5 ) ) ; + } + # if you have exabytes (EiB) of email to transfer, you have too much email! + } + #myprint( "$bytes = $readable_value\n" ) ; + + return( $readable_value ) ; +} + sub tests_useheader_suggestion { @@ -14209,10 +14838,10 @@ sub do_and_print_stats myprint( "Messages deleted on host2 : $mysync->{ acc2 }->{ nb_msg_deleted }\n" ) ; myprintf( "Total bytes transferred : %s (%s)\n", $mysync->{total_bytes_transferred}, - bytes_display_string( $mysync->{total_bytes_transferred} ) ) ; + bytes_display_string_bin( $mysync->{total_bytes_transferred} ) ) ; myprintf( "Total bytes skipped : %s (%s)\n", $mysync->{ total_bytes_skipped }, - bytes_display_string( $mysync->{ total_bytes_skipped } ) ) ; + bytes_display_string_bin( $mysync->{ total_bytes_skipped } ) ) ; $timediff ||= 1 ; # No division per 0 myprintf("Message rate : %.1f messages/s\n", $mysync->{nb_msg_transferred} / $timediff ) ; myprintf("Average bandwidth rate : %.1f KiB/s\n", $mysync->{total_bytes_transferred} / $KIBI / $timediff ) ; @@ -14225,7 +14854,7 @@ sub do_and_print_stats myprint( "CPU time and %cpu : $cpu_time sec $cpu_percent %cpu $cpu_percent_global %allcpus\n" ) ; myprintf("Biggest message transferred : %s bytes (%s)\n", $mysync->{ biggest_message_transferred }, - bytes_display_string( $mysync->{ biggest_message_transferred } ) ) ; + bytes_display_string_bin( $mysync->{ biggest_message_transferred } ) ) ; myprint( "Memory/biggest message ratio : $memory_ratio\n" ) ; if ( $mysync->{ foldersizesatend } and $mysync->{ foldersizes } ) { @@ -14235,21 +14864,21 @@ sub do_and_print_stats myprintf("Start difference host2 - host1 : %s messages, %s bytes (%s)\n", $nb_msg_start_diff, $bytes_start_diff, - bytes_display_string( $bytes_start_diff ) ) ; + bytes_display_string_bin( $bytes_start_diff ) ) ; my $nb_msg_end_diff = diff_or_NA( $h2_nb_msg_end, $h1_nb_msg_end ) ; my $bytes_end_diff = diff_or_NA( $h2_bytes_end, $h1_bytes_end ) ; myprintf("Final difference host2 - host1 : %s messages, %s bytes (%s)\n", $nb_msg_end_diff, $bytes_end_diff, - bytes_display_string( $bytes_end_diff ) ) ; + bytes_display_string_bin( $bytes_end_diff ) ) ; } comment_on_final_diff_in_1_not_in_2( $mysync ) ; comment_on_final_diff_in_2_not_in_1( $mysync ) ; myprint( "Detected $mysync->{nb_errors} errors\n\n" ) ; - myprint( $warn_release, "\n" ) ; + myprint( $mysync->{ warn_release }, "\n" ) ; myprint( homepage( ), "\n" ) ; return ; } @@ -14696,7 +15325,7 @@ sub file_to_array if ( ! -e $file ) { return ; } if ( ! -f $file ) { return ; } if ( ! -r $file ) { return ; } - + my @string ; if ( open my $FILE, '<', $file ) @@ -14741,7 +15370,7 @@ sub file_to_string if ( ! -e $file ) { return ; } if ( ! -f $file ) { return ; } if ( ! -r $file ) { return ; } - + return( join q{}, file_to_array( $file ) ) ; } @@ -15236,7 +15865,7 @@ sub tests_cpu_number } is( 4, cpu_number( ), "cpu_number: on i005 (FreeBSD) => 4" ) ; } ; - + SKIP: { if ( ! ( 'petite' eq hostname() ) ) { @@ -15252,7 +15881,7 @@ sub tests_cpu_number } is( 2, cpu_number( ), "cpu_number: on polarhome macosx (Darwin MacOS X 10.7.5 Lion) => 2" ) ; } ; - + SKIP: { if ( ! ( 'pcHPDV7-HP' eq hostname() ) ) { @@ -15260,7 +15889,7 @@ sub tests_cpu_number } is( 2, cpu_number( ), "cpu_number: on pcHPDV7-HP (Windows 7, 64bits) => 2" ) ; } ; - + SKIP: { if ( ! ( 'CUILLERE' eq hostname() ) ) { @@ -15268,7 +15897,7 @@ sub tests_cpu_number } is( 1, cpu_number( ), "cpu_number: on CUILLERE (Windows XP, 32bits) => 1" ) ; } ; - + note( 'Leaving tests_cpu_number()' ) ; return ; @@ -15288,33 +15917,33 @@ sub cpu_number { $cpu_number = $ENV{"NUMBER_OF_PROCESSORS"} ; #myprint( "Number of processors found by env var NUMBER_OF_PROCESSORS: $cpu_number\n" ) ; } - + if ( 'darwin' eq $OSNAME ) { $cpu_number = backtick( "sysctl -n hw.ncpu" ) ; chomp( $cpu_number ) ; #myprint( "Number of processors found by cmd 'sysctl -n hw.ncpu': $cpu_number\n" ) ; } - + if ( 'freebsd' eq $OSNAME ) { $cpu_number = backtick( "sysctl -n kern.smp.cpus" ) ; chomp( $cpu_number ) ; #myprint( "Number of processors found by cmd 'sysctl -n kern.smp.cpus': $cpu_number\n" ) ; } - + if ( 'linux' eq $OSNAME && -e '/proc/cpuinfo' ) { @cpuinfo = file_to_array( '/proc/cpuinfo' ) ; $cpu_number = grep { /^processor/mxs } @cpuinfo ; #myprint( "Number of processors found via /proc/cpuinfo: $cpu_number\n" ) ; } - + if ( defined $cpu_number_forced ) { $cpu_number = $cpu_number_forced ; } - + return( integer_or_1( $cpu_number ) ) ; } @@ -15375,13 +16004,16 @@ sub tests_loadavg { note( 'Entering tests_loadavg()' ) ; - SKIP: { - skip( 'Tests for darwin', 2 ) if ('darwin' ne $OSNAME) ; + skip( 'Tests for darwin', 3 ) if ('darwin' ne $OSNAME) ; is( undef, loadavg( '/noexist' ), 'loadavg: /noexist => undef' ) ; - is_deeply( [ '0.11', '0.22', '0.33' ], - [ loadavg( 'W/t/loadavg.out' ) ], - 'loadavg W/t/loadavg.out => 0.11 0.22 0.33' ) ; + is_deeply( + [ '0.11', '0.22', '0.33' ], + [ loadavg( 'vm.loadavg: { 0.11 0.22 0.33 }' ) ], + 'loadavg: "vm.loadavg: { 0.11 0.22 0.33 }" => 0.11 0.22 0.33' + ) ; + note( join( " ", "loadavg:", loadavg( ) ) ) ; + is( 3, scalar( my @loadavg = loadavg( ) ), 'loadavg: 3 values' ) ; } ; SKIP: { @@ -15399,7 +16031,6 @@ sub tests_loadavg is_deeply( [ 0 ], [ loadavg( ) ], 'loadavg on MSWin32 => 0' ) ; - } ; note( 'Leaving tests_loadavg()' ) ; @@ -15422,7 +16053,6 @@ sub loadavg return ( loadavg_windows( @ARG ) ) ; } return( 'unknown' ) ; - } sub loadavg_linux @@ -15466,24 +16096,25 @@ sub loadavg_freebsd sub loadavg_darwin { - my $file = shift ; + my $line = shift ; # Example of output of command "sysctl vm.loadavg": # vm.loadavg: { 0.15 0.08 0.08 } my $loadavg ; - if ( ! defined $file ) { + if ( ! defined $line ) { eval { - $loadavg = `/usr/sbin/sysctl vm.loadavg` ; + # $loadavg = `/usr/sbin/sysctl vm.loadavg` ; + $loadavg = `LANG= /usr/sbin/sysctl vm.loadavg` ; #myprint( "LOADAVG DARWIN: $loadavg\n" ) ; } ; if ( $EVAL_ERROR ) { myprint( "[$EVAL_ERROR]\n" ) ; return ; } }else{ - $loadavg = firstline( $file ) or return ; + $loadavg = $line ; } my ( $avg_1_min, $avg_5_min, $avg_15_min ) = $loadavg =~ /vm\.loadavg\s*[:=]\s*\{?\s*(\d+\.?\d*)\s+(\d+\.?\d*)\s+(\d+\.?\d*)/mxs ; - $sync->{ debug } and myprint( "System load: $avg_1_min $avg_5_min $avg_15_min\n" ) ; + #$sync->{ debug } and myprint( "System load: $avg_1_min $avg_5_min $avg_15_min\n" ) ; return ( $avg_1_min, $avg_5_min, $avg_15_min ) ; } @@ -15592,7 +16223,7 @@ sub tests_cpu_time my $mysync = { } ; $mysync->{ debug } = 1 ; - ok( is_number( cpu_time( $mysync ) ), 'cpu_time: {} => a number' ) ; + ok( is_number( cpu_time( $mysync ) ), 'cpu_time: {} => a number' ) ; note( 'Leaving tests_cpu_time()' ) ; return ; @@ -15601,15 +16232,15 @@ sub tests_cpu_time sub cpu_time { my $mysync = shift ; - + my @cpu_times = times ; if ( ! @cpu_times ) { return ; } - + my $cpu_time = 0 ; # last element is the sum of all elements $cpu_time = ( map { $cpu_time += $_ } @cpu_times )[ -1 ] ; - $mysync->{ debug } and myprint( join(' + ', @cpu_times), " = $cpu_time\n" ) ; - + my $cpu_time_round = mysprintf( '%.2f', $cpu_time ) ; + $mysync->{ debug } and myprint( join(' + ', @cpu_times), " = $cpu_time ~ $cpu_time_round\n" ) ; return $cpu_time ; } @@ -15644,9 +16275,9 @@ sub cpu_percent my $cpu_percent = 0 ; $cpu_percent = mysprintf( '%.1f', 100 * $cpu_time / $timediff ) ; $mysync->{ debug } and myprint( "cpu_percent: $cpu_percent \n" ) ; - + return $cpu_percent ; - + } sub tests_cpu_percent_global @@ -15666,7 +16297,7 @@ sub tests_cpu_percent_global } is( '25.0', cpu_percent_global( $mysync, 100 ), 'cpu_percent_global: {} 100 => 25 on host i005' ) ; } ; - + SKIP: { if ( ! ( 'petite' eq hostname() ) ) { @@ -15683,13 +16314,13 @@ sub cpu_percent_global { my $mysync = shift ; my $cpu_percent = shift || 0 ; - + my $cpu_number = cpu_number( ) ; - + my $cpu_percent_global ; $cpu_percent_global = mysprintf( '%.1f', $cpu_percent / $cpu_number ) ; $mysync->{ debug } and myprint( "cpu_percent_global: $cpu_percent_global \n" ) ; - + return( $cpu_percent_global ) ; } @@ -15720,7 +16351,6 @@ sub tests_memory_stress sub memory_stress { - my $total_ram_in_MB = Sys::MemInfo::get("totalmem") / ( $KIBI * $KIBI ) ; my $i = 1 ; @@ -15728,13 +16358,13 @@ sub memory_stress while ( $i < $total_ram_in_MB / 1.7 ) { $a .= "A" x 1000_000; $i++ } ; myprintf("Stress memory consumption after: %.1f MiB\n", memory_consumption( ) / $KIBI / $KIBI ) ; return ; - } sub tests_memory_consumption { note( 'Entering tests_memory_consumption()' ) ; + note( "memory_consumption: " . memory_consumption() . " bytes aka " . bytes_display_string_dec( memory_consumption() ) ) ; like( memory_consumption( ), qr{\d+}xms,'memory_consumption no args') ; like( memory_consumption( 1 ), qr{\d+}xms,'memory_consumption 1') ; like( memory_consumption( $PROCESS_ID ), qr{\d+}xms,"memory_consumption_of_pids $PROCESS_ID") ; @@ -15743,7 +16373,6 @@ sub tests_memory_consumption like( memory_consumption_ratio(1), qr{\d+}xms, 'memory_consumption_ratio 1' ) ; like( memory_consumption_ratio(10), qr{\d+}xms, 'memory_consumption_ratio 10' ) ; - like( memory_consumption(), qr{\d+}xms, "memory_consumption\n" ) ; note( 'Leaving tests_memory_consumption()' ) ; return ; @@ -15774,23 +16403,36 @@ sub memory_consumption_of_pids my @val ; if ( ( 'MSWin32' eq $OSNAME ) or ( 'cygwin' eq $OSNAME ) ) { @val = memory_consumption_of_pids_win32( @pid ) ; - }else{ + } + elsif ( 'darwin' eq $OSNAME ) + { + @val = memory_consumption_of_pids_mac( @pid ) ; + } + else + { # Unix my @ps = qx{ ps -o vsz -p @pid } ; - #myprint( "ps: @ps" ) ; - - # Use IPC::Open3 from perlcrit -3 - # But it stalls on Darwin, I don't understand why! - #my @ps = backtick( "ps -o vsz -p @pid" ) ; - #myprint( "ps: @ps" ) ; - - shift @ps; # First line is column name "VSZ" - chomp @ps; + shift @ps ; # First line is column name "VSZ" + chomp @ps ; # convert to octets @val = map { $_ * $KIBI } @ps ; } - $sync->{ debug } and myprint( "@val\n" ) ; + return( @val ) ; +} + + +sub memory_consumption_of_pids_mac +{ + my @pid = @_ ; + # Use IPC::Open3 from perlcrit -3 + # But it stalls on Darwin, I don't understand why! + #my @ps = backtick( "ps -o rss -p @pid" ) ; + #myprint( "ps: @ps" ) ; + my @ps = qx{ ps -o rss -p @pid } ; + shift @ps ; # First line is column name "RSS" + chomp @ps ; + my @val = map { $_ * $KIBI } @ps ; return( @val ) ; } @@ -16439,7 +17081,7 @@ sub comment_on_final_diff_in_2_not_in_1 " among ", $nb_identified_h2_messages, " identified messages in host2 that are not on host1.", - " Use --delete2 and sync again to delete them and have a strict sync.\n" + " Use --delete2 and sync again to delete them and have a strict sync.\n" ) ; } return ; @@ -17114,6 +17756,24 @@ sub max_line_length return( $max ) ; } +sub set_checknoabletosearch +{ + my $mysync = shift @ARG ; + if ( defined $mysync->{ checknoabletosearch } ) + { + return ; + } + elsif ( $mysync->{ justfolders } ) + { + $mysync->{ checknoabletosearch } = 0 ; + } + else + { + $mysync->{ checknoabletosearch } = 1 ; + } + return ; +} + sub tests_setlogfile { @@ -17215,7 +17875,7 @@ sub setlogfile # When aborting another process the log file name finishes with "_abort.txt" my $abort_suffix = ( $mysync->{ abort } ) ? '_abort' : q{} ; - + # When acting as a proxy the log file name finishes with "_remote.txt" # proxy mode is not done in imapsync, it is done by proximapsync my $remote_suffix = ( $mysync->{ remote } ) ? '_remote' : q{} ; @@ -17313,13 +17973,13 @@ sub tests_localtimez sub localtimez { my $time = shift ; - + $time = defined( $time ) ? $time : time ; - + my $datetimestr = POSIX::strftime( '%A %e %B %Y-%m-%d %H:%M:%S %z %Z', localtime( $time ) ) ; #myprint( "$datetimestr\n" ) ; - return $datetimestr ; + return $datetimestr ; } @@ -17761,6 +18421,7 @@ sub gmail12 $skipcrossduplicates = ( defined $skipcrossduplicates ) ? $skipcrossduplicates : 0 ; $mysync->{ synclabels } = ( defined $mysync->{ synclabels } ) ? $mysync->{ synclabels } : 1 ; $mysync->{ resynclabels } = ( defined $mysync->{ resynclabels } ) ? $mysync->{ resynclabels } : 1 ; + push @useheader, 'X-Gmail-Received', 'Message-Id' ; push @exclude, '\[Gmail\]$' ; push @folderlast, '[Gmail]/All Mail' ; return ; @@ -17785,7 +18446,7 @@ sub gmail1 return ; } -sub gmail2 +sub gmail2 { my $mysync = shift ; # Gmail at host2 @@ -18610,8 +19271,8 @@ sub setvalfromcgikey my ( $mysync, $mycgi, $key, $val ) = @ARG ; my $badthings = 0 ; - - + + my ( $name, $type, $struct ) ; if ( $key !~ m/^([\w\d\|]+)([=:][isf])?([\+!\@\%])?$/mxs ) { @@ -18624,7 +19285,7 @@ sub setvalfromcgikey $type = $2 ; # = or : followed by i or s or f $struct = $3 ; # + or ! or @ or % } - + if ( ( $struct || q{} ) eq '+' ) { ${$val} = $mycgi->param( $name ) ; # "Incremental" integer @@ -18638,7 +19299,7 @@ sub setvalfromcgikey { setvalfromhash( $val, $type, @values ) ; } - else + else { setvalfromlist( $mysync, $val, $name, $type, $struct, @values ) ; } @@ -18647,7 +19308,7 @@ sub setvalfromcgikey { setvalfromcheckbox( $mysync, $mycgi, $key, $name, $val ) ; } - + return $badthings ; } @@ -18681,7 +19342,7 @@ sub setvalfromlist else { } - + return ; } sub setvalfromhash @@ -18708,11 +19369,11 @@ sub setvalfromhash { %{ ${$val} } = %values ; } - else + else { %{$val} = %values ; } - + return ; } @@ -18720,7 +19381,7 @@ sub setvalfromhash sub setvalfromcheckbox { my ( $mysync, $mycgi, $key, $name, $val ) = @ARG ; - + # Checkbox # --noname is set by name=0 or name= my $value = $mycgi->param( $name ) ; @@ -18774,7 +19435,7 @@ sub myGetOptions $badthings += setvalfromcgikey( $mysync, $mycgi, $key, $val ) ; } - + if ( $badthings ) { return ; # undef or () } @@ -18785,6 +19446,138 @@ sub myGetOptions +sub tests_get_options_extra +{ + note( 'Entering tests_get_options_extra()' ) ; + + is( undef, get_options_extra( ), 'get_options_extra: no args => undef' ) ; + + my $mysync = { } ; + is( undef, get_options_extra( $mysync ), 'get_options_extra: undef => undef' ) ; + + my $cwd_save = getcwd( ) ; + + ok( (-d 'W/tmp/tests/options_extra/' or mkpath( 'W/tmp/tests/options_extra/' )), 'get_options_extra: mkpath W/tmp/tests/options_extra/' ) ; + + chdir 'W/tmp/tests/options_extra/' ; + + is( '--debugimap1', string_to_file( '--debugimap1', 'options_extra.txt' ), 'get_options_extra: string_to_file filling options_extra.txt with --debugimap1' ) ; + + is( '--debugimap1', file_to_string( 'options_extra.txt' ), 'get_options_extra: reading options_extra.txt is --debugimap1' ) ; + + is( '', get_options_extra( $mysync ), 'get_options_extra: --debugimap1 in options_extra.txt => nothing left, empty string return' ) ; + + is( 1, $mysync->{ acc1 }->{ debugimap }, 'get_options_extra: --debugimap1 in options_extra.txt => ok, acc1->debugimap = 1' ) ; + + is( '--tls1 proutcaca', string_to_file( '--tls1 proutcaca', 'options_extra.txt' ), 'get_options_extra: string_to_file filling options_extra.txt with --tls1 proutcaca' ) ; + + is( 'proutcaca', get_options_extra( $mysync ), 'get_options_extra: --tls1 proutcaca in options_extra.txt => proutcaca left, proutcaca return' ) ; + + chdir $cwd_save ; + + note( 'Leaving tests_get_options_extra()' ) ; + return ; +} + +sub get_options_extra +{ + my $mysync = shift @ARG ; + + if ( ! defined $mysync ) { return ; } + + if ( -f -r 'options_extra.txt' ) + { + my $cwd = getcwd( ) ; + my $string = firstline( 'options_extra.txt' ) ; + my $rest = get_options_from_string( $mysync, $string ) ; + output( $mysync, "Reading extra options from file options_extra.txt (cwd: $cwd) : $string\n" ) ; + return $rest ; + } + else + { + return ; + } +} + + +sub tests_get_options_from_string +{ + note( 'Entering tests_get_options_from_string()' ) ; + + is( undef, get_options_from_string( ), 'get_options_from_string: no args => undef' ) ; + my $mysync = { } ; + is( undef, get_options_from_string( $mysync ), 'get_options_from_string: undef => undef' ) ; + + is( '', get_options_from_string( $mysync, '--debugimap1' ), + 'get_options_from_string: --debugimap1 => ok, nothing left, empty string return' ) ; + is( 1, $mysync->{ acc1 }->{ debugimap }, 'get_options_from_string: --debugimap1 => ok, acc1->debugimap = 1' ) ; + + $mysync = { } ; # reset + is( 'caca', get_options_from_string( $mysync, '--debugimap1 caca' ), + 'get_options_from_string: --debugimap1 caca => ok, caca left, caca return' ) ; + is( 1, $mysync->{ acc1 }->{ debugimap }, 'get_options_from_string: --debugimap1 => ok, acc1->debugimap = 1' ) ; + + is( 'popo roro', get_options_from_string( $mysync, '--debugimap2 popo roro' ), + 'get_options_from_string: --debugimap1 popo roro => ok, popo roro left, popo roro return' ) ; + is( 1, $mysync->{ acc2 }->{ debugimap }, 'get_options_from_string: --debugimap2 popo roro => ok, acc2->debugimap = 1' ) ; + is( 1, $mysync->{ acc1 }->{ debugimap }, 'get_options_from_string: acc1->debugimap = 1 still' ) ; + + is( '', get_options_from_string( $mysync, '--nodebugimap1 --debugflags --errorsmax 2' ), + 'get_options_from_string: --nodebugimap1 --debugflags --errorsmax 2 => ok, empty string return' ) ; + + is( 0, $mysync->{ acc1 }->{ debugimap }, 'get_options_from_string: acc1->debugimap = 0 now' ) ; + is( 1, $debugflags, 'get_options_from_string: debugflags = 1 now' ) ; + is( 2, $mysync->{ errorsmax }, 'get_options_from_string: mysync->errorsmax = 2 now' ) ; + + is( '', get_options_from_string( $mysync, '--folder "IN BOX" --folder JOE' ), + 'get_options_from_string: --folder "IN BOX" --folder JOE => ok, empty string return' ) ; + + is_deeply( [ 'IN BOX', 'JOE' ], [@{$mysync->{ folder }}], 'get_options_from_string: "IN BOX" "JOE"' ) ; + + is( '', get_options_from_string( $mysync, '--debugflags --koko' ), + 'get_options_from_string: --debugflags --koko => ok, empty string return, with "Unknown option: koko" on STDERR' ) ; + + note( 'Leaving tests_get_options_from_string()' ) ; + return ; +} + +sub get_options_from_string +{ + my $mysync = shift @ARG ; + my $mystring = shift @ARG ; + + if ( ! defined $mystring ) { return ; } + + my ( $ret, $args ) = Getopt::Long::GetOptionsFromString( $mystring, + 'debugimap!' => \$mysync->{ debugimap }, + 'debugimap1!' => \$mysync->{ acc1 }->{ debugimap }, + 'debugimap2!' => \$mysync->{ acc2 }->{ debugimap }, + 'debugflags!' => \$debugflags, + 'debugsleep=f' => \$mysync->{ debugsleep }, + 'errorsmax=i' => \$mysync->{ errorsmax }, + 'folder=s@' => \$mysync->{ folder }, + 'timeout=f' => \$mysync->{ timeout }, + 'timeout1=f' => \$mysync->{ acc1 }->{ timeout }, + 'timeout2=f' => \$mysync->{ acc2 }->{ timeout }, + 'keepalive1!' => \$mysync->{ acc1 }->{ keepalive }, + 'keepalive2!' => \$mysync->{ acc2 }->{ keepalive }, + 'reconnectretry1=i' => \$mysync->{ acc1 }->{ reconnectretry }, + 'reconnectretry2=i' => \$mysync->{ acc2 }->{ reconnectretry }, + 'ssl1!' => \$mysync->{ ssl1 }, + 'ssl2!' => \$mysync->{ ssl2 }, + 'tls1!' => \$mysync->{ tls1 }, + 'tls2!' => \$mysync->{ tls2 }, + 'compress1!' => \$mysync->{ acc1 }->{ compress }, + 'compress2!' => \$mysync->{ acc2 }->{ compress }, + ) ; + my $left = join( ' ', @$args ) ; + return $left ; +} + + + + + sub tests_get_options_cgi_context { @@ -18922,6 +19715,8 @@ sub get_options_cgi 'ssl2!' => \$mysync->{ ssl2 }, 'tls1!' => \$mysync->{ tls1 }, 'tls2!' => \$mysync->{ tls2 }, + 'compress1!' => \$mysync->{ acc1 }->{ compress }, + 'compress2!' => \$mysync->{ acc2 }->{ compress }, 'justbanner!' => \$mysync->{ justbanner }, 'justlogin!' => \$mysync->{ justlogin }, 'justconnect!' => \$mysync->{ justconnect }, @@ -18957,7 +19752,7 @@ sub get_options_cgi 'syncduplicates!' => \$mysync->{ syncduplicates }, 'log!' => \$mysync->{ log }, 'loglogfile!' => \$mysync->{ loglogfile }, - + # f1f2h=s% could be removed but # tests_get_options_cgi() should be split before @@ -18991,8 +19786,8 @@ sub get_options_cmd \@arguments, 'debug!' => \$mysync->{ debug }, 'debuglist!' => \$debuglist, - 'debugcontent!' => \$debugcontent, - 'debugsleep=f' => \$mysync->{debugsleep}, + 'debugcontent!' => \$mysync->{ debugcontent }, + 'debugsleep=f' => \$mysync->{ debugsleep }, 'debugflags!' => \$debugflags, 'debugimap!' => \$mysync->{ debugimap }, 'debugimap1!' => \$mysync->{ acc1 }->{ debugimap }, @@ -19012,10 +19807,10 @@ sub get_options_cmd 'host1=s' => \$mysync->{ host1 }, 'host2=s' => \$mysync->{ host2 }, - 'port1=i' => \$mysync->{port1}, - 'port2=i' => \$mysync->{port2}, - 'inet4|ipv4' => \$mysync->{inet4}, - 'inet6|ipv6' => \$mysync->{inet6}, + 'port1=i' => \$mysync->{ port1 }, + 'port2=i' => \$mysync->{ port2 }, + 'inet4|ipv4' => \$mysync->{ inet4 }, + 'inet6|ipv6' => \$mysync->{ inet6 }, 'user1=s' => \$mysync->{ user1 }, 'user2=s' => \$mysync->{ user2 }, 'gmail1' => \$mysync->{gmail1}, @@ -19109,7 +19904,6 @@ sub get_options_cmd 'justbanner!' => \$mysync->{ justbanner }, 'justfolders!'=> \$mysync->{ justfolders }, 'justfoldersizes!' => \$mysync->{ justfoldersizes }, - 'fast!' => \$fast, 'version' => \$mysync->{version}, 'help' => \$help, 'timeout=f' => \$mysync->{timeout}, @@ -19140,6 +19934,10 @@ sub get_options_cmd 'authuser2=s' => \$mysync->{ acc2 }->{ authuser }, 'proxyauth1' => \$mysync->{ acc1 }->{ proxyauth }, 'proxyauth2' => \$mysync->{ acc2 }->{ proxyauth }, + 'compress1!' => \$mysync->{ acc1 }->{ compress }, + 'compress2!' => \$mysync->{ acc2 }->{ compress }, + 'keepalive1!' => \$mysync->{ acc1 }->{ keepalive }, + 'keepalive2!' => \$mysync->{ acc2 }->{ keepalive }, 'split1=i' => \$split1, 'split2=i' => \$split2, 'buffersize=i' => \$buffersize, @@ -19191,7 +19989,7 @@ sub get_options_cmd 'logfile=s' => \$mysync->{logfile}, 'logdir=s' => \$mysync->{logdir}, 'errorsmax=i' => \$mysync->{errorsmax}, - 'errorsdump!' => \$mysync->{errorsdump}, + 'errorsdump!' => \$mysync->{ errorsdump }, 'fetch_hash_set=s' => \$fetch_hash_set, 'automap!' => \$mysync->{automap}, 'justautomap!' => \$mysync->{justautomap}, @@ -19204,7 +20002,7 @@ sub get_options_cmd 'checknoabletosearch!' => \$mysync->{checknoabletosearch}, 'syncduplicates!' => \$mysync->{ syncduplicates }, 'dockercontext!' => \$mysync->{ dockercontext }, - + ) ; #myprint( Data::Dumper->Dump( [ $mysync ] ) ) ; @@ -19294,6 +20092,7 @@ sub get_options $ret = get_options_cmd( $mysync, @arguments ) ; } ; #myprint( "2 mysync: ", Data::Dumper->Dump( [ $mysync ] ) ) ; + foreach my $key ( sort keys %{ $mysync } ) { if ( ! defined $mysync->{$key} ) { delete $mysync->{$key} ; @@ -19308,6 +20107,31 @@ sub get_options } +sub tests_infos +{ + note( 'Entering tests_infos()' ) ; + note( "OSNAME=$OSNAME" ) ; + note( "hostname=". hostname() ) ; + note( "cwd=" . getcwd( ) ) ; + note( "PROGRAM_NAME=$PROGRAM_NAME" ) ; + my $stat = stat("$PROGRAM_NAME") ; + my $perms = sprintf( "%04o\n", $stat->mode & oct($PERMISSION_FILTER) ) ; + note( "permissions=$perms" ) ; + note( "PROCESS_ID=$PROCESS_ID" ) ; + note( "REAL_USER_ID=$REAL_USER_ID" ) ; + note( "EFFECTIVE_USER_ID=$EFFECTIVE_USER_ID" ) ; + note( "context: " . imapsync_context( $sync ) ) ; + note( "memory_consumption: " . memory_consumption() . " bytes aka " . bytes_display_string_dec( memory_consumption() ) ) ; + cpu_number + note( "cpu_number: " . cpu_number() ) ; + note( $sync->{rcs} ) ; + + note( 'Leaving tests_infos()' ) ; + return ; +} + + + sub condition_to_leave_after_tests { my $mysync = shift ; @@ -19316,9 +20140,9 @@ sub condition_to_leave_after_tests return 0 ; } - if ( $mysync->{ tests } - or $mysync->{ testsdebug } - or $mysync->{ testsunit } + if ( $mysync->{ tests } + or $mysync->{ testsdebug } + or $mysync->{ testsunit } ) { return 1 ; @@ -19467,8 +20291,9 @@ sub testsdebug #tests_kill_zero( ) ; #tests_connect_socket( ) ; #tests_probe_imapssl( ) ; - tests_cpu_number( ) ; - tests_mailimapclient_connect( ) ; + #tests_cpu_number( ) ; + #tests_mailimapclient_connect( ) ; + tests_loadavg( ) ; #tests_always_fail( ) ; note( 'Leaving testsdebug()' ) ; @@ -19524,7 +20349,8 @@ sub tests tests_time_remaining( ) ; tests_decompose_regex( ) ; tests_backtick( ) ; - tests_bytes_display_string( ) ; + tests_bytes_display_string_bin( ) ; + tests_bytes_display_string_dec( ) ; tests_header_line_normalize( ) ; tests_fix_Inbox_INBOX_mapping( ) ; tests_max_line_length( ) ; @@ -19666,6 +20492,14 @@ sub tests tests_cpu_percent_global( ) ; tests_flags_for_host2( ) ; tests_under_docker_context( ) ; + tests_exit_value( ) ; + tests_comment_of_error_type( ) ; + tests_debugcontent( ) ; + tests_compress_ssl( ) ; + tests_compress( ) ; + tests_get_options_extra( ) ; + tests_get_options_from_string( ) ; + tests_infos( ) ; #tests_resolv( ) ; # Those three are for later use, when webserver will be inside imapsync @@ -19675,7 +20509,7 @@ sub tests #tests_kill_zero( ) ; #tests_always_fail( ) ; - done_testing( 1742 ) ; + done_testing( 1860 ) ; note( 'Leaving tests()' ) ; } return ; @@ -19698,6 +20532,6 @@ sub tests_template sub template { my $mysync = shift @ARG ; - + return ; } diff --git a/data/Dockerfiles/dovecot/quarantine_notify.py b/data/Dockerfiles/dovecot/quarantine_notify.py index acd887a0..f60a3226 100755 --- a/data/Dockerfiles/dovecot/quarantine_notify.py +++ b/data/Dockerfiles/dovecot/quarantine_notify.py @@ -161,7 +161,7 @@ try: attrs = json.loads(attrs.decode('utf-8')) if attrs['quarantine_notification'] not in ('hourly', 'daily', 'weekly'): continue - if last_notification == 0 or (last_notification + time_trans[attrs['quarantine_notification']]) < time_now: + if last_notification == 0 or (last_notification + time_trans[attrs['quarantine_notification']]) <= time_now: print("Notifying %s: Considering %d new items in quarantine (policy: %s)" % (record['rcpt'], record['counter'], attrs['quarantine_notification'])) notify_rcpt(record['rcpt'], record['counter'], record['quarantine_acl'], attrs['quarantine_category']) diff --git a/data/Dockerfiles/dovecot/syslog-ng-redis_slave.conf b/data/Dockerfiles/dovecot/syslog-ng-redis_slave.conf index f6905092..ea2bcfbf 100644 --- a/data/Dockerfiles/dovecot/syslog-ng-redis_slave.conf +++ b/data/Dockerfiles/dovecot/syslog-ng-redis_slave.conf @@ -1,4 +1,4 @@ -@version: 3.19 +@version: 3.28 @include "scl.conf" options { chain_hostnames(off); diff --git a/data/Dockerfiles/dovecot/syslog-ng.conf b/data/Dockerfiles/dovecot/syslog-ng.conf index bdaca9cb..2ee4f624 100644 --- a/data/Dockerfiles/dovecot/syslog-ng.conf +++ b/data/Dockerfiles/dovecot/syslog-ng.conf @@ -1,4 +1,4 @@ -@version: 3.19 +@version: 3.28 @include "scl.conf" options { chain_hostnames(off); diff --git a/data/Dockerfiles/olefy/Dockerfile b/data/Dockerfiles/olefy/Dockerfile index af156d35..a1a42482 100644 --- a/data/Dockerfiles/olefy/Dockerfile +++ b/data/Dockerfiles/olefy/Dockerfile @@ -8,9 +8,9 @@ RUN apk add --virtual .build-deps gcc musl-dev python3-dev libffi-dev openssl-de && apk add --update --no-cache python3 py3-pip openssl tzdata libmagic \ && pip3 install --upgrade pip \ && pip3 install --upgrade asyncio python-magic \ - && pip3 install --upgrade https://github.com/HeinleinSupport/oletools/archive/master.zip \ + && pip3 install --upgrade https://github.com/decalage2/oletools/archive/master.zip \ && apk del .build-deps -# && sed -i 's/decompress_stream(bytearray(compressed_code))/bytes2str(decompress_stream(bytearray(compressed_code)))/g' /usr/lib/python3.8/site-packages/oletools/olevba.py +# && sed -i 's/template_injection_detected = True/template_injection_detected = False/g' /usr/lib/python3.9/site-packages/oletools/olevba.py ADD olefy.py /app/ diff --git a/data/Dockerfiles/rspamd/Dockerfile b/data/Dockerfiles/rspamd/Dockerfile index ee08f8d2..23fcbb3f 100644 --- a/data/Dockerfiles/rspamd/Dockerfile +++ b/data/Dockerfiles/rspamd/Dockerfile @@ -21,7 +21,8 @@ RUN apt-get update && apt-get install -y \ && apt-get clean \ && mkdir -p /run/rspamd \ && chown _rspamd:_rspamd /run/rspamd \ - && echo 'alias ll="ls -la --color"' >> ~/.bashrc + && echo 'alias ll="ls -la --color"' >> ~/.bashrc \ + && sed -i 's/#analysis_keyword_table > 0/analysis_cat_table.macro_exist == "M"/g' /usr/share/rspamd/lualib/lua_scanners/oletools.lua COPY settings.conf /etc/rspamd/settings.conf COPY metadata_exporter.lua /usr/share/rspamd/plugins/metadata_exporter.lua diff --git a/data/assets/nextcloud/nextcloud.conf b/data/assets/nextcloud/nextcloud.conf index e143a791..3755c4a7 100644 --- a/data/assets/nextcloud/nextcloud.conf +++ b/data/assets/nextcloud/nextcloud.conf @@ -47,6 +47,14 @@ server { return 301 $client_req_scheme_nc://$host/remote.php/dav; } + location = /.well-known/webfinger { + return 301 $client_req_scheme_nc://$host/index.php/.well-known/webfinger; + } + + location = /.well-known/nodeinfo { + return 301 $client_req_scheme_nc://$host/index.php/.well-known/nodeinfo; + } + location ^~ /.well-known/acme-challenge/ { default_type "text/plain"; root /web; diff --git a/data/conf/nginx/includes/site-defaults.conf b/data/conf/nginx/includes/site-defaults.conf index b38f4b2d..f618c110 100644 --- a/data/conf/nginx/includes/site-defaults.conf +++ b/data/conf/nginx/includes/site-defaults.conf @@ -163,7 +163,9 @@ proxy_connect_timeout 75; proxy_send_timeout 3600; proxy_read_timeout 3600; - proxy_buffers 64 256k; + proxy_buffer_size 128k; + proxy_buffers 64 512k; + proxy_busy_buffers_size 512k; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; @@ -197,6 +199,9 @@ proxy_set_header x-webobjects-server-name $server_name; proxy_set_header x-webobjects-server-url $client_req_scheme://$http_host; proxy_set_header x-webobjects-server-port $server_port; + proxy_buffer_size 128k; + proxy_buffers 64 512k; + proxy_busy_buffers_size 512k; proxy_send_timeout 3600; proxy_read_timeout 3600; client_body_buffer_size 128k; diff --git a/data/conf/phpfpm/php-conf.d/opcache-recommended.ini b/data/conf/phpfpm/php-conf.d/opcache-recommended.ini index 104f2425..3c51e11b 100644 --- a/data/conf/phpfpm/php-conf.d/opcache-recommended.ini +++ b/data/conf/phpfpm/php-conf.d/opcache-recommended.ini @@ -1,6 +1,6 @@ opcache.enable=1 opcache.enable_cli=1 -opcache.interned_strings_buffer=8 +opcache.interned_strings_buffer=16 opcache.max_accelerated_files=10000 opcache.memory_consumption=128 opcache.save_comments=1 diff --git a/data/conf/postfix/postscreen_access.cidr b/data/conf/postfix/postscreen_access.cidr index 63c7342b..5509433b 100644 --- a/data/conf/postfix/postscreen_access.cidr +++ b/data/conf/postfix/postscreen_access.cidr @@ -1,53 +1,63 @@ -# Whitelist generated by Postwhite v3.4 on Sun Dec 15 21:16:19 CET 2019 +# Whitelist generated by Postwhite v3.4 on Mon 21 Mar 2022 06:50:26 PM CET # https://github.com/stevejenkins/postwhite/ -# 1928 total rules +# 1898 total rules 2a00:1450:4000::/36 permit 2a01:111:f400::/48 permit 2a01:111:f403::/48 permit +2a01:4180:4050:0400::/64 permit +2a01:4180:4050:0800::/64 permit +2a01:4180:4051:0400::/64 permit +2a01:4180:4051:0800::/64 permit 2a02:a60:0:5::/64 permit 2c0f:fb50:4000::/36 permit -3.93.157.0/24 permit 8.20.114.31 permit 8.25.194.0/23 permit 8.25.196.0/23 permit 8.39.54.0/23 permit 8.40.222.0/23 permit -8.45.169.0/24 permit 12.130.86.238 permit +13.70.32.43 permit +13.72.50.45 permit +13.74.143.28 permit 13.77.161.179 permit +13.78.233.182 permit +13.92.31.129 permit +13.110.208.0/21 permit +13.110.216.0/22 permit +13.110.224.0/20 permit 13.111.0.0/16 permit -13.111.0.0/22 permit -13.111.52.0/22 permit -13.111.63.0/24 permit -13.111.68.0/24 permit -13.111.72.0/22 permit -13.111.92.0/24 permit -13.111.111.0/24 permit -17.36.0.0/16 permit 17.41.0.0/16 permit +17.57.155.0/24 permit +17.57.156.0/24 permit 17.58.0.0/16 permit 17.110.0.0/15 permit -17.111.110.0/23 permit -17.120.0.0/16 permit -17.133.0.0/16 permit -17.139.0.0/16 permit 17.142.0.0/15 permit -17.151.1.0/24 permit -17.158.0.0/15 permit 17.162.0.0/15 permit 17.164.0.0/16 permit 17.171.37.0/24 permit 17.172.0.0/16 permit 17.179.168.0/23 permit 18.194.95.56 permit -18.208.124.128/25 permit +18.198.96.88 permit +20.47.149.138 permit +20.48.0.0/12 permit +20.52.52.2 permit +20.52.128.133 permit +20.63.210.192/28 permit +20.64.0.0/10 permit +20.94.180.64/28 permit +20.185.213.160/27 permit +20.185.213.224/27 permit 20.185.214.0/27 permit 20.185.214.2 permit 20.185.214.32/27 permit 20.185.214.64/27 permit -23.23.237.213 permit -23.103.131.7 permit +20.192.0.0/10 permit +23.100.85.1 permit 23.103.224.0/19 permit +23.249.208.0/20 permit +23.251.224.0/19 permit +23.253.141.0/24 permit 23.253.182.0/23 permit 23.253.182.103 permit 23.253.183.145 permit @@ -68,11 +78,11 @@ 27.123.206.56/29 permit 27.123.206.76/30 permit 27.123.206.80/28 permit -27.126.146.0/24 permit -34.200.123.20 permit +34.194.25.167 permit +34.194.144.120 permit 34.212.163.75 permit -34.213.104.127 permit 34.225.212.172 permit +34.247.168.44 permit 35.176.132.251 permit 35.190.247.0/24 permit 35.191.0.0/16 permit @@ -80,7 +90,10 @@ 37.218.248.47 permit 37.218.249.47 permit 37.218.251.62 permit +39.156.163.64/29 permit +40.71.187.0/24 permit 40.76.4.15 permit +40.77.102.222 permit 40.92.0.0/15 permit 40.97.116.82 permit 40.97.128.194 permit @@ -91,18 +104,20 @@ 40.97.161.50 permit 40.97.164.146 permit 40.107.0.0/16 permit +40.112.65.63 permit 40.112.72.205 permit 40.113.200.201 permit +40.117.80.0/24 permit +40.121.71.46 permit 41.74.192.0/22 permit 41.74.196.0/22 permit 41.74.200.0/23 permit -41.74.201.0/24 permit 41.74.204.0/23 permit -41.74.205.0/24 permit +41.74.206.0/24 permit 42.159.163.81 permit 42.159.163.82 permit 42.159.163.83 permit -46.19.168.0/23 permit +43.228.184.0/22 permit 46.226.48.0/21 permit 46.228.36.37 permit 46.228.36.38/31 permit @@ -160,26 +175,19 @@ 50.18.125.97 permit 50.18.125.237 permit 50.18.126.162 permit -50.23.218.192/27 permit 50.31.32.0/19 permit -50.31.36.197 permit -50.31.36.199 permit -50.31.36.205 permit -50.31.36.208 permit -50.31.36.213 permit -50.31.44.111 permit -50.31.57.54/31 permit -50.31.57.60 permit -50.31.57.61 permit -50.31.57.62 permit -50.31.60.1 permit 50.31.156.96/27 permit 50.31.205.0/24 permit -50.207.218.237 permit 51.4.71.62 permit +51.4.72.0/24 permit +51.4.80.0/27 permit +51.5.72.0/24 permit +51.5.80.0/27 permit +51.137.58.21 permit +51.140.75.55 permit +51.144.100.179 permit 51.163.158.0/24 permit -51.163.159.0/24 permit -52.0.20.102 permit +51.163.159.21 permit 52.5.230.59 permit 52.27.5.72 permit 52.27.28.47 permit @@ -190,10 +198,15 @@ 52.41.64.145 permit 52.60.41.5 permit 52.60.115.116 permit +52.82.172.0/22 permit +52.94.124.0/28 permit 52.95.48.152/29 permit 52.95.49.88/29 permit 52.100.0.0/14 permit -52.128.40.0/21 permit +52.119.213.144/28 permit +52.160.39.140 permit +52.165.175.144 permit +52.185.106.240/28 permit 52.200.59.0/24 permit 52.205.61.79 permit 52.207.191.216 permit @@ -201,26 +214,30 @@ 52.222.73.83 permit 52.222.73.120 permit 52.222.75.85 permit +52.234.172.96/28 permit +52.236.28.240/28 permit +52.237.141.173 permit +52.244.206.214 permit +52.247.53.144 permit +52.250.107.196 permit +52.250.126.174 permit +52.251.55.143 permit 54.90.148.255 permit 54.156.255.69 permit 54.172.97.247 permit -54.173.229.38 permit -54.174.52.0/24 permit -54.174.53.128/30 permit -54.174.57.0/24 permit -54.174.59.0/24 permit -54.174.60.0/23 permit -54.174.63.0/24 permit 54.186.193.102 permit +54.191.223.5 permit +54.194.61.95 permit +54.195.113.45 permit 54.214.39.184 permit +54.216.77.168 permit 54.240.0.0/18 permit -54.240.40.0/25 permit -54.240.56.128/26 permit -54.240.63.0/25 permit +54.240.64.0/19 permit +54.240.96.0/19 permit 54.241.16.209 permit -54.243.205.80 permit 54.244.54.130 permit 54.244.242.0/24 permit +54.246.232.180 permit 62.13.128.0/24 permit 62.13.129.128/25 permit 62.13.136.0/22 permit @@ -231,9 +248,9 @@ 62.13.152.0/23 permit 62.17.146.128/26 permit 62.140.7.0/24 permit -62.140.10.0/24 permit +62.140.10.21 permit +63.32.13.159 permit 63.80.14.0/23 permit -63.111.28.137 permit 63.128.21.0/24 permit 63.143.57.128/25 permit 63.143.59.128/25 permit @@ -241,9 +258,11 @@ 64.20.241.45 permit 64.34.47.128/27 permit 64.34.57.192/26 permit +64.71.149.160/28 permit 64.79.155.0/24 permit -64.79.155.192 permit -64.89.45.192/30 permit +64.89.44.85 permit +64.89.45.80 permit +64.89.45.194 permit 64.89.45.196 permit 64.95.144.196 permit 64.127.115.252 permit @@ -265,21 +284,21 @@ 64.207.219.7 permit 64.207.219.8 permit 64.207.219.9 permit -64.207.219.10 permit -64.207.219.11 permit -64.207.219.12 permit +64.207.219.13 permit +64.207.219.14 permit +64.207.219.15 permit 64.207.219.71 permit 64.207.219.72 permit 64.207.219.73 permit -64.207.219.74 permit -64.207.219.75 permit -64.207.219.76 permit +64.207.219.77 permit +64.207.219.78 permit +64.207.219.79 permit 64.207.219.135 permit 64.207.219.136 permit 64.207.219.137 permit -64.207.219.138 permit -64.207.219.139 permit -64.207.219.140 permit +64.207.219.141 permit +64.207.219.142 permit +64.207.219.143 permit 64.233.160.0/19 permit 65.38.115.76 permit 65.38.115.84 permit @@ -288,7 +307,6 @@ 65.54.51.64/26 permit 65.54.61.64/26 permit 65.54.121.120/29 permit -65.54.121.124/31 permit 65.54.190.0/24 permit 65.54.241.0/24 permit 65.55.29.77 permit @@ -298,7 +316,6 @@ 65.55.52.224/27 permit 65.55.78.128/25 permit 65.55.81.48/28 permit -65.55.81.54/31 permit 65.55.90.0/24 permit 65.55.94.0/25 permit 65.55.111.0/24 permit @@ -325,9 +342,6 @@ 66.111.4.225 permit 66.111.4.229 permit 66.111.4.230 permit -66.135.202.0/27 permit -66.135.215.0/24 permit -66.135.222.1 permit 66.162.193.226/31 permit 66.163.184.0/21 permit 66.163.184.0/24 permit @@ -358,7 +372,8 @@ 66.196.81.232/31 permit 66.196.81.234 permit 66.211.168.230/31 permit -66.211.184.0/23 permit +66.211.170.86/31 permit +66.211.170.88/30 permit 66.218.74.64/30 permit 66.218.74.68/31 permit 66.218.75.112/30 permit @@ -420,9 +435,7 @@ 67.221.168.65 permit 67.228.2.24/30 permit 67.228.21.184/29 permit -67.228.34.32/27 permit 67.228.37.4/30 permit -67.228.50.54/31 permit 67.231.145.42 permit 67.231.153.30 permit 68.142.230.0/24 permit @@ -432,17 +445,6 @@ 68.142.230.72/30 permit 68.142.230.76/31 permit 68.142.230.78 permit -68.232.131.164 permit -68.232.131.172 permit -68.232.131.183 permit -68.232.131.185 permit -68.232.143.44 permit -68.232.145.216 permit -68.232.148.56 permit -68.232.148.128 permit -68.232.148.138 permit -68.232.157.60 permit -68.232.157.143 permit 68.232.192.0/20 permit 69.63.178.128/25 permit 69.63.181.0/24 permit @@ -456,9 +458,9 @@ 69.171.232.0/24 permit 69.171.244.0/23 permit 70.37.151.128/25 permit +70.42.149.0/24 permit 70.42.149.35 permit 72.3.185.0/24 permit -72.3.237.64/28 permit 72.14.192.0/18 permit 72.21.192.0/19 permit 72.21.217.142 permit @@ -523,8 +525,10 @@ 72.32.154.0/24 permit 72.32.217.0/24 permit 72.32.243.0/24 permit -72.34.168.75 permit 72.34.168.76 permit +72.34.168.80 permit +72.34.168.85 permit +72.34.168.86 permit 72.52.72.32/28 permit 72.52.72.36 permit 74.6.128.0/21 permit @@ -536,9 +540,6 @@ 74.6.133.0/24 permit 74.6.134.0/24 permit 74.6.135.0/24 permit -74.63.63.115 permit -74.63.63.121 permit -74.63.194.126 permit 74.63.212.0/24 permit 74.63.234.75 permit 74.63.236.0/24 permit @@ -557,17 +558,9 @@ 74.112.67.243 permit 74.125.0.0/16 permit 74.202.227.40 permit -74.208.4.192/26 permit -74.208.5.64/26 permit -74.208.122.0/26 permit 74.209.250.0/24 permit 74.209.250.12 permit -75.126.253.48 permit -76.223.176.0/24 permit -76.223.180.0/23 permit -76.223.188.0/24 permit -76.223.189.0/24 permit -76.223.190.0/24 permit +76.223.176.0/20 permit 77.238.176.0/22 permit 77.238.176.0/24 permit 77.238.177.0/24 permit @@ -590,13 +583,11 @@ 77.238.189.146/31 permit 77.238.189.148/30 permit 81.223.46.0/27 permit -82.165.159.0/24 permit -82.165.159.0/26 permit -82.165.229.130 permit -82.165.230.22 permit 84.16.77.1 permit 85.158.136.0/21 permit 86.61.88.25 permit +87.198.219.130 permit +87.198.219.153 permit 87.238.80.0/21 permit 87.248.103.12 permit 87.248.103.21 permit @@ -633,11 +624,9 @@ 87.248.117.201 permit 87.248.117.202 permit 87.248.117.205 permit +87.252.219.254 permit 87.253.232.0/21 permit 89.22.108.0/24 permit -91.194.248.0/23 permit -91.211.240.0/22 permit -91.211.243.0/24 permit 91.220.42.0/24 permit 94.236.119.0/26 permit 94.245.112.0/27 permit @@ -649,7 +638,6 @@ 96.43.148.64/28 permit 96.43.148.64/31 permit 96.43.151.64/28 permit -96.46.150.192/27 permit 98.136.44.181 permit 98.136.44.182/31 permit 98.136.44.184 permit @@ -1152,20 +1140,25 @@ 98.139.245.180/31 permit 98.139.245.208/30 permit 98.139.245.212/31 permit +99.78.197.208/28 permit +103.2.140.0/22 permit 103.9.8.121 permit 103.9.8.122 permit 103.9.8.123 permit 103.9.96.0/22 permit 103.13.69.0/24 permit -103.28.42.0/24 permit -103.96.20.0/24 permit -103.96.22.0/24 permit +103.47.204.0/22 permit +103.96.21.0/24 permit +103.96.23.0/24 permit +103.151.192.0/23 permit 103.237.104.0/22 permit 104.43.243.237 permit 104.47.0.0/17 permit 104.130.96.0/28 permit 104.130.122.0/23 permit +104.214.25.77 permit 104.215.148.63 permit +104.215.186.3 permit 104.245.209.192/26 permit 106.10.144.64/27 permit 106.10.144.100/31 permit @@ -1291,6 +1284,7 @@ 106.10.242.0/24 permit 106.10.243.0/24 permit 106.10.244.0/24 permit +106.39.212.64/29 permit 106.50.16.0/28 permit 108.174.0.0/24 permit 108.174.0.215 permit @@ -1302,13 +1296,14 @@ 108.175.30.45 permit 108.177.8.0/21 permit 108.177.96.0/19 permit -108.178.6.0/24 permit 109.237.142.0/24 permit 111.221.23.128/25 permit 111.221.26.0/27 permit 111.221.66.0/25 permit 111.221.69.128/25 permit 111.221.112.0/21 permit +112.19.199.64/29 permit +112.19.242.64/29 permit 116.214.12.0/24 permit 116.214.12.47 permit 116.214.12.48/31 permit @@ -1325,6 +1320,7 @@ 117.120.16.0/21 permit 119.42.242.52/31 permit 119.42.242.156 permit +123.126.78.64/29 permit 124.47.150.0/24 permit 124.47.189.0/24 permit 124.108.96.0/24 permit @@ -1332,11 +1328,19 @@ 124.108.96.28/31 permit 124.108.96.70/31 permit 124.108.96.72/31 permit +128.17.0.0/20 permit +128.17.64.0/20 permit +128.17.128.0/20 permit +128.17.192.0/20 permit 128.127.70.0/26 permit +128.245.0.0/20 permit +128.245.64.0/20 permit 129.41.77.70 permit 129.41.169.249 permit +129.146.236.58 permit +129.153.194.228 permit +129.159.87.137 permit 130.61.9.72 permit -130.61.68.235 permit 130.211.0.0/22 permit 130.248.172.0/24 permit 130.248.173.0/24 permit @@ -1345,8 +1349,10 @@ 131.253.121.0/26 permit 131.253.121.20 permit 131.253.121.52 permit -132.145.11.129 permit 132.145.13.209 permit +132.226.26.225 permit +132.226.49.32 permit +132.226.56.24 permit 134.170.27.8 permit 134.170.113.0/26 permit 134.170.141.64/26 permit @@ -1356,21 +1362,27 @@ 135.84.82.0/24 permit 135.84.216.0/22 permit 136.143.182.0/23 permit -136.143.188.0/23 permit +136.143.184.0/24 permit +136.143.188.0/24 permit 136.147.128.0/20 permit 136.147.135.0/24 permit 136.147.176.0/20 permit 136.147.176.0/24 permit 136.147.182.0/24 permit +138.91.172.26 permit 139.60.152.0/22 permit 139.178.64.159 permit 139.178.64.195 permit -139.180.17.0/24 permit 141.193.32.0/23 permit +143.55.224.0/21 permit +143.55.232.0/22 permit +143.55.236.0/22 permit +144.178.36.0/24 permit +144.178.38.0/24 permit 146.20.112.0/26 permit 146.20.113.0/24 permit 146.20.191.0/24 permit -146.88.28.0/24 permit +146.20.215.0/24 permit 146.101.78.0/24 permit 147.75.65.173 permit 147.75.65.174 permit @@ -1384,10 +1396,7 @@ 148.105.0.14 permit 148.105.8.0/21 permit 149.72.0.0/16 permit -151.101.1.140 permit -151.101.65.140 permit -151.101.129.140 permit -151.101.193.140 permit +152.67.105.195 permit 157.55.0.192/26 permit 157.55.1.128/26 permit 157.55.2.0/25 permit @@ -1397,6 +1406,7 @@ 157.55.61.0/24 permit 157.55.157.128/25 permit 157.55.225.0/25 permit +157.55.254.216 permit 157.56.24.0/25 permit 157.56.120.128/26 permit 157.56.232.0/21 permit @@ -1405,21 +1415,26 @@ 157.58.196.96/29 permit 157.58.249.3 permit 157.151.208.65 permit -158.247.16.0/20 permit +157.255.1.64/29 permit +159.92.157.0/24 permit +159.92.158.0/24 permit +159.92.159.0/24 permit +159.92.160.0/24 permit +159.92.161.0/24 permit +159.92.162.0/24 permit +159.135.132.128/25 permit +159.135.140.80/29 permit 159.135.224.0/20 permit -161.38.192.0/22 permit -161.38.196.0/22 permit -161.71.32.0/21 permit +159.183.0.0/16 permit +161.38.192.0/20 permit +161.38.204.0/22 permit +161.71.32.0/19 permit +161.71.64.0/20 permit 162.208.119.181 permit 162.247.216.0/22 permit -162.248.184.121 permit -162.248.184.122 permit -162.248.185.121 permit -162.248.185.122 permit -162.248.186.121 permit -162.248.186.122 permit -163.47.180.0/22 permit +163.47.180.0/23 permit 163.114.130.16 permit +163.114.132.120 permit 166.78.68.0/22 permit 166.78.68.221 permit 166.78.69.146 permit @@ -1427,16 +1442,7 @@ 166.78.69.170 permit 166.78.71.131 permit 167.89.0.0/17 permit -167.89.2.4 permit -167.89.22.44 permit -167.89.25.84 permit -167.89.31.192/29 permit -167.89.32.5 permit -167.89.32.50 permit 167.89.46.159 permit -167.89.46.185 permit -167.89.60.95 permit -167.89.62.118 permit 167.89.64.9 permit 167.89.65.0 permit 167.89.65.53 permit @@ -1448,22 +1454,15 @@ 167.89.75.164 permit 167.89.101.2 permit 167.89.101.192/28 permit -167.89.107.125 permit -167.89.107.127 permit -167.89.107.129 permit -167.89.107.136 permit -167.216.129.170 permit -167.216.129.182/31 permit -167.216.129.184/29 permit -167.216.129.192/29 permit -167.216.129.200 permit -167.216.129.205 permit -167.216.129.206/31 permit -167.216.129.208/31 permit 167.216.129.210 permit +167.216.131.180 permit 167.220.67.232/29 permit 167.220.67.238 permit +168.138.5.36 permit 168.245.0.0/17 permit +170.10.68.0/22 permit +170.10.129.0/24 permit +170.10.133.0/24 permit 172.217.0.0/19 permit 172.217.32.0/20 permit 172.217.128.0/19 permit @@ -1473,8 +1472,6 @@ 172.253.112.0/20 permit 173.0.84.224/27 permit 173.0.94.244/30 permit -173.193.132.134/31 permit -173.193.210.32/27 permit 173.194.0.0/16 permit 173.203.79.182 permit 173.203.81.39 permit @@ -1482,7 +1479,6 @@ 173.224.160.188 permit 173.224.161.128/25 permit 173.228.155.0/24 permit -173.236.20.0/24 permit 174.36.84.8/29 permit 174.36.84.16/29 permit 174.36.84.32/29 permit @@ -1494,30 +1490,25 @@ 174.36.114.148/30 permit 174.36.114.152/29 permit 174.37.67.28/30 permit -174.37.226.64/27 permit -174.129.194.241 permit 174.129.203.189 permit -174.137.46.0/24 permit 176.32.105.0/24 permit 176.32.127.0/24 permit 178.236.10.128/26 permit 180.189.28.0/24 permit 182.50.76.0/22 permit 182.50.78.64/28 permit -184.173.105.0/24 permit -184.173.153.0/24 permit -185.4.120.0/24 permit -185.4.122.0/24 permit +183.240.219.64/29 permit 185.12.80.0/22 permit 185.28.196.0/22 permit -185.58.84.0/24 permit -185.58.87.0/24 permit +185.58.84.93 permit +185.58.85.0/24 permit +185.58.86.0/24 permit 185.72.128.75 permit 185.72.128.76 permit +185.72.128.80 permit 185.80.93.204 permit 185.80.93.227 permit 185.80.95.31 permit -185.90.20.0/22 permit 185.189.236.0/22 permit 185.211.120.0/22 permit 185.250.236.0/22 permit @@ -1577,7 +1568,6 @@ 192.64.236.0/24 permit 192.64.237.0/24 permit 192.64.238.0/24 permit -192.92.97.0/24 permit 192.161.144.0/20 permit 192.162.87.0/24 permit 192.237.158.0/23 permit @@ -1589,37 +1579,34 @@ 192.254.113.10 permit 192.254.113.101 permit 192.254.114.176 permit -192.254.115.72 permit 192.254.118.63 permit -192.254.127.96/27 permit +193.7.206.0/25 permit +193.7.207.0/25 permit 193.109.254.0/23 permit -194.64.234.128/27 permit +193.122.128.100 permit 194.64.234.129 permit +194.104.109.0/24 permit +194.104.111.0/24 permit 194.106.220.0/23 permit -194.113.24.0/22 permit 194.154.193.192/27 permit -195.54.172.0/23 permit 195.130.217.0/24 permit +195.234.109.226 permit 195.245.230.0/23 permit 198.2.128.0/18 permit 198.2.128.0/24 permit 198.2.132.0/22 permit 198.2.136.0/23 permit +198.2.145.0/24 permit 198.2.177.0/24 permit -198.2.178.0/24 permit -198.2.179.0/24 permit +198.2.178.0/23 permit 198.2.180.0/24 permit 198.2.186.0/23 permit 198.21.0.0/21 permit -198.21.3.166 permit -198.21.4.224 permit 198.37.144.0/20 permit -198.37.145.250 permit -198.37.146.118/31 permit -198.37.149.128 permit -198.37.151.26 permit +198.37.152.186 permit 198.61.254.0/23 permit 198.61.254.231 permit +198.74.56.28 permit 198.178.234.57 permit 198.245.80.0/20 permit 198.245.81.0/24 permit @@ -1636,18 +1623,15 @@ 199.122.120.0/21 permit 199.122.123.0/24 permit 199.127.232.0/22 permit -199.201.64.23 permit -199.201.65.23 permit 199.255.192.0/22 permit 202.129.242.0/23 permit 202.165.102.47 permit 202.177.148.100 permit 202.177.148.110 permit +203.31.36.0/22 permit 203.32.4.25 permit -203.55.21.0/24 permit 203.81.17.0/24 permit 203.122.32.250 permit -203.145.57.160/27 permit 203.188.194.32 permit 203.188.194.151 permit 203.188.194.203 permit @@ -1680,32 +1664,30 @@ 203.188.201.12/30 permit 203.209.230.75 permit 203.209.230.76/31 permit -204.2.193.0/29 permit 204.11.168.0/21 permit 204.13.11.48/29 permit -204.13.11.48/30 permit 204.14.232.0/21 permit 204.14.232.64/28 permit 204.14.234.64/28 permit 204.29.186.0/23 permit -204.75.142.0/24 permit 204.79.197.212 permit 204.92.114.187 permit 204.92.114.203 permit 204.92.114.204/31 permit 204.141.32.0/23 permit 204.141.42.0/23 permit -204.153.120.0/23 permit +204.153.121.0/24 permit +204.232.168.0/24 permit 205.139.110.0/24 permit -205.139.111.0/24 permit 205.201.128.0/20 permit 205.201.131.128/25 permit 205.201.134.128/25 permit 205.201.136.0/23 permit -205.201.137.229 permit 205.201.139.0/24 permit 205.207.104.0/22 permit 205.207.104.108 permit +205.220.167.17 permit +205.220.179.17 permit 205.251.233.32 permit 205.251.233.36 permit 206.25.247.143 permit @@ -1727,6 +1709,8 @@ 207.46.132.128/27 permit 207.46.198.0/25 permit 207.46.200.0/27 permit +207.46.225.107 permit +207.58.147.64/28 permit 207.67.38.0/24 permit 207.67.98.192/27 permit 207.68.176.0/26 permit @@ -1734,7 +1718,8 @@ 207.82.80.0/24 permit 207.126.144.0/20 permit 207.171.160.0/19 permit -207.211.30.0/24 permit +207.211.30.64/26 permit +207.211.30.128/25 permit 207.211.31.0/25 permit 207.211.41.113 permit 207.218.90.0/24 permit @@ -1743,7 +1728,7 @@ 208.43.21.28/30 permit 208.43.21.64/29 permit 208.43.21.72/30 permit -208.43.239.136/30 permit +208.46.212.80 permit 208.46.212.208/31 permit 208.46.212.210 permit 208.64.132.0/22 permit @@ -1773,13 +1758,13 @@ 208.71.42.212/31 permit 208.71.42.214 permit 208.72.249.240/29 permit -208.74.204.0/22 permit 208.74.204.9 permit 208.75.120.0/22 permit 208.75.122.246 permit -208.82.236.96/28 permit -208.82.237.96/28 permit -208.82.238.96/28 permit +208.82.237.96/29 permit +208.82.237.104/31 permit +208.82.238.96/29 permit +208.82.238.104/31 permit 208.85.50.137 permit 208.117.48.0/20 permit 208.185.229.45 permit @@ -1792,10 +1777,10 @@ 209.67.98.59 permit 209.85.128.0/17 permit 212.4.136.0/26 permit -212.25.240.75 permit -212.25.240.76 permit +212.25.240.80 permit 212.25.240.83 permit -212.25.240.84 permit +212.25.240.84/31 permit +212.25.240.88 permit 212.82.96.0/24 permit 212.82.96.32/27 permit 212.82.96.64/29 permit @@ -1836,13 +1821,8 @@ 212.82.111.228/31 permit 212.82.111.230 permit 212.123.28.40 permit -212.227.15.0/24 permit -212.227.15.0/25 permit -212.227.17.0/27 permit -212.227.126.128/25 permit -213.165.64.0/23 permit -213.167.75.0/24 permit -213.167.81.0/24 permit +213.167.75.0/25 permit +213.167.81.0/25 permit 213.199.128.139 permit 213.199.128.145 permit 213.199.138.181 permit @@ -1851,6 +1831,7 @@ 213.199.177.0/26 permit 216.17.150.242 permit 216.17.150.251 permit +216.22.15.224/27 permit 216.24.224.0/20 permit 216.39.60.0/23 permit 216.39.60.154/31 permit @@ -1877,17 +1858,9 @@ 216.39.62.60/31 permit 216.39.62.136/29 permit 216.39.62.144/31 permit -216.46.168.197 permit -216.46.168.222 permit -216.52.185.88/29 permit +216.46.168.0/24 permit 216.58.192.0/19 permit 216.66.217.240/29 permit -216.71.96.0/22 permit -216.71.152.175 permit -216.71.152.207 permit -216.71.154.29 permit -216.71.155.88 permit -216.71.155.89 permit 216.74.162.13 permit 216.74.162.14 permit 216.82.240.0/20 permit @@ -1897,9 +1870,6 @@ 216.109.114.0/24 permit 216.109.114.32/27 permit 216.109.114.64/29 permit -216.113.160.0/24 permit -216.113.172.0/25 permit -216.113.175.0/24 permit 216.128.126.97 permit 216.136.162.65 permit 216.136.162.120/29 permit @@ -1909,14 +1879,13 @@ 216.203.33.178/31 permit 216.205.24.0/24 permit 216.239.32.0/19 permit -217.72.192.64/26 permit -217.72.192.248/29 permit -217.72.207.0/27 permit 217.77.141.52 permit 217.77.141.59 permit -217.175.193.0/24 permit -217.175.194.0/23 permit -217.175.196.0/24 permit +222.73.195.64/29 permit +223.165.113.0/24 permit +223.165.115.0/24 permit +223.165.118.0/23 permit +223.165.120.0/23 permit 2001:4860:4000::/36 permit 2404:6800:4000::/36 permit 2607:f8b0:4000::/36 permit @@ -1925,6 +1894,7 @@ 2620:109:c006:104::215 permit 2620:109:c006:104::/64 permit 2620:109:c00d:104::/64 permit +2620:10d:c090:450::120 permit 2620:10d:c091:450::16 permit 2620:119:50c0:207::215 permit 2620:119:50c0:207::/64 permit diff --git a/data/conf/rspamd/lua/ivm-sg.lua b/data/conf/rspamd/lua/ivm-sg.lua deleted file mode 100644 index 6642fe4d..00000000 --- a/data/conf/rspamd/lua/ivm-sg.lua +++ /dev/null @@ -1,61 +0,0 @@ --- Thanks to https://raw.githubusercontent.com/fatalbanana - -local lua_maps = require 'lua_maps' -local rspamd_regexp = require 'rspamd_regexp' -local rspamd_util = require 'rspamd_util' - -local ivm_sendgrid_ids = lua_maps.map_add_from_ucl( - 'https://www.invaluement.com/spdata/sendgrid-id-dnsbl.txt', - 'set', - 'Invaluement Service Provider DNSBL: Sendgrid IDs' -) - -local ivm_sendgrid_envfromdomains = lua_maps.map_add_from_ucl( - 'https://www.invaluement.com/spdata/sendgrid-envelopefromdomain-dnsbl.txt', - 'set', - 'Invaluement Service Provider DNSBL: Sendgrid envelope domains' -) - -local cb_id = rspamd_config:register_symbol({ - name = 'IVM_SENDGRID', - callback = function(task) - -- Is it Sendgrid? - local sg_hdr = task:get_header('X-SG-EID') - if not sg_hdr then return end - - -- Get original envelope from - local env_from = task:get_from{'smtp', 'orig'} - if not env_from then return end - - -- Check normalised domain in domains list - if ivm_sendgrid_envfromdomains and ivm_sendgrid_envfromdomains:get_key(rspamd_util.get_tld(env_from[1].domain)) then - task:insert_result('IVM_SENDGRID_DOMAIN', 1.0) - end - - -- Check ID in ID list - local lp_re = rspamd_regexp.create_cached([[^bounces\+(\d+)-]]) - local res = lp_re:search(env_from[1].user, true, true) - if not res then return end - if ivm_sendgrid_ids and ivm_sendgrid_ids:get_key(res[1][2]) then - task:insert_result('IVM_SENDGRID_ID', 1.0) - end - end, - description = 'Invaluement Service Provider DNSBL: Sendgrid', - type = 'callback', -}) - -rspamd_config:register_symbol({ - name = 'IVM_SENDGRID_DOMAIN', - parent = cb_id, - group = 'ivmspdnsbl', - score = 8.0, - type = 'virtual', -}) - -rspamd_config:register_symbol({ - name = 'IVM_SENDGRID_ID', - parent = cb_id, - group = 'ivmspdnsbl', - score = 8.0, - type = 'virtual', -}) diff --git a/data/web/autodiscover.php b/data/web/autodiscover.php index cc6807ba..992524b3 100644 --- a/data/web/autodiscover.php +++ b/data/web/autodiscover.php @@ -68,7 +68,7 @@ if (empty($_SERVER['PHP_AUTH_USER']) || empty($_SERVER['PHP_AUTH_PW'])) { exit(0); } -$login_role = check_login($login_user, $login_pass, true); +$login_role = check_login($login_user, $login_pass, array('eas' => TRUE)); if ($login_role === "user") { header("Content-Type: application/xml"); diff --git a/data/web/css/build/008-mailcow.css b/data/web/css/build/008-mailcow.css index d7533424..d04feb25 100644 --- a/data/web/css/build/008-mailcow.css +++ b/data/web/css/build/008-mailcow.css @@ -207,6 +207,7 @@ legend { } .footer .version { margin-left: auto; + margin-top: 20px; } .slave-info { padding: 15px 0px 15px 15px; diff --git a/data/web/inc/functions.mailbox.inc.php b/data/web/inc/functions.mailbox.inc.php index 21b6b130..dccdcd93 100644 --- a/data/web/inc/functions.mailbox.inc.php +++ b/data/web/inc/functions.mailbox.inc.php @@ -4054,6 +4054,10 @@ function mailbox($_action, $_type, $_data = null, $_extra = null) { $stmt->execute(array( ':alias_domain' => $alias_domain, )); + $stmt = $pdo->prepare("DELETE FROM `spamalias` WHERE `address` LIKE :domain"); + $stmt->execute(array( + ':domain' => '%@'.$alias_domain, + )); $stmt = $pdo->prepare("DELETE FROM `bcc_maps` WHERE `local_dest` = :alias_domain"); $stmt->execute(array( ':alias_domain' => $alias_domain, diff --git a/data/web/inc/init_db.inc.php b/data/web/inc/init_db.inc.php index 3cab461e..8e8a63b5 100644 --- a/data/web/inc/init_db.inc.php +++ b/data/web/inc/init_db.inc.php @@ -3,7 +3,7 @@ function init_db_schema() { try { global $pdo; - $db_version = "18012022_1020"; + $db_version = "22032022_1330"; $stmt = $pdo->query("SHOW TABLES LIKE 'versions'"); $num_results = count($stmt->fetchAll(PDO::FETCH_ASSOC)); @@ -864,7 +864,7 @@ function init_db_schema() { "sogo_sessions_folder" => array( "cols" => array( "c_id" => "VARCHAR(255) NOT NULL", - "c_value" => "VARCHAR(255) NOT NULL", + "c_value" => "VARCHAR(4096) NOT NULL", "c_creationdate" => "INT(11) NOT NULL", "c_lastseen" => "INT(11) NOT NULL" ), diff --git a/data/web/inc/lib/composer.lock b/data/web/inc/lib/composer.lock index b1507525..870382f3 100644 --- a/data/web/inc/lib/composer.lock +++ b/data/web/inc/lib/composer.lock @@ -62,35 +62,40 @@ "oauth", "oauth2" ], + "support": { + "issues": "https://github.com/bshaffer/oauth2-server-php/issues", + "source": "https://github.com/bshaffer/oauth2-server-php/tree/master" + }, "time": "2018-12-04T00:29:32+00:00" }, { "name": "ddeboer/imap", - "version": "1.12.1", + "version": "1.13.1", "source": { "type": "git", "url": "https://github.com/ddeboer/imap.git", - "reference": "dbed05ca67b93509345a820b2859de10c48948fb" + "reference": "8b772d04b1deadb5df13782fb78c4b648f77496e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ddeboer/imap/zipball/dbed05ca67b93509345a820b2859de10c48948fb", - "reference": "dbed05ca67b93509345a820b2859de10c48948fb", + "url": "https://api.github.com/repos/ddeboer/imap/zipball/8b772d04b1deadb5df13782fb78c4b648f77496e", + "reference": "8b772d04b1deadb5df13782fb78c4b648f77496e", "shasum": "" }, "require": { "ext-iconv": "*", "ext-imap": "*", "ext-mbstring": "*", - "php": "^7.4 || ^8.0" + "php": "^8.0.1" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.18.6", - "laminas/laminas-mail": "^2.14.0", - "phpstan/phpstan": "^0.12.84", - "phpstan/phpstan-phpunit": "^0.12.18", - "phpstan/phpstan-strict-rules": "^0.12.9", - "phpunit/phpunit": "^9.5.4" + "friendsofphp/php-cs-fixer": "^v3.4.0", + "laminas/laminas-mail": "^2.15.1", + "malukenho/mcbumpface": "^1.1.5", + "phpstan/phpstan": "^1.3.3", + "phpstan/phpstan-phpunit": "^1.0.0", + "phpstan/phpstan-strict-rules": "^1.1.0", + "phpunit/phpunit": "^9.5.11" }, "type": "library", "autoload": { @@ -124,7 +129,7 @@ ], "support": { "issues": "https://github.com/ddeboer/imap/issues", - "source": "https://github.com/ddeboer/imap/tree/1.12.1" + "source": "https://github.com/ddeboer/imap/tree/1.13.1" }, "funding": [ { @@ -136,35 +141,35 @@ "type": "github" } ], - "time": "2021-04-27T08:38:46+00:00" + "time": "2022-01-10T10:53:05+00:00" }, { "name": "directorytree/ldaprecord", - "version": "v2.6.3", + "version": "v2.10.1", "source": { "type": "git", "url": "https://github.com/DirectoryTree/LdapRecord.git", - "reference": "5c93ec6d1ef458290825a8b0a148946dce7c1e7a" + "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/5c93ec6d1ef458290825a8b0a148946dce7c1e7a", - "reference": "5c93ec6d1ef458290825a8b0a148946dce7c1e7a", + "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/bf512d9af7a7b0e2ed7a666ab29cefdd027bee88", + "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88", "shasum": "" }, "require": { "ext-json": "*", "ext-ldap": "*", - "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0", + "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0|^9.0", "nesbot/carbon": "^1.0|^2.0", "php": ">=7.3", - "psr/log": "^1.0", - "psr/simple-cache": "^1.0", + "psr/log": "*", + "psr/simple-cache": "^1.0|^2.0", "tightenco/collect": "^5.6|^6.0|^7.0|^8.0" }, "require-dev": { "mockery/mockery": "^1.0", - "phpunit/phpunit": "^8.0", + "phpunit/phpunit": "^9.0", "spatie/ray": "^1.24" }, "type": "library", @@ -209,31 +214,31 @@ "type": "github" } ], - "time": "2021-08-05T21:52:43+00:00" + "time": "2022-02-25T16:00:51+00:00" }, { "name": "illuminate/contracts", - "version": "v8.53.1", + "version": "v9.3.0", "source": { "type": "git", "url": "https://github.com/illuminate/contracts.git", - "reference": "504a34286a1b4c5421c43087d6bd4e176138f6fb" + "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/illuminate/contracts/zipball/504a34286a1b4c5421c43087d6bd4e176138f6fb", - "reference": "504a34286a1b4c5421c43087d6bd4e176138f6fb", + "url": "https://api.github.com/repos/illuminate/contracts/zipball/bf4b3c254c49d28157645d01e4883b5951b1e1d0", + "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0", "shasum": "" }, "require": { - "php": "^7.3|^8.0", - "psr/container": "^1.0", - "psr/simple-cache": "^1.0" + "php": "^8.0.2", + "psr/container": "^1.1.1|^2.0.1", + "psr/simple-cache": "^1.0|^2.0|^3.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "8.x-dev" + "dev-master": "9.x-dev" } }, "autoload": { @@ -257,7 +262,7 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2021-08-03T14:03:47+00:00" + "time": "2022-02-22T14:45:39+00:00" }, { "name": "matthiasmullie/minify", @@ -384,6 +389,10 @@ "paths", "relative" ], + "support": { + "issues": "https://github.com/matthiasmullie/path-converter/issues", + "source": "https://github.com/matthiasmullie/path-converter/tree/1.1.3" + }, "time": "2019-02-05T23:41:09+00:00" }, { @@ -438,16 +447,16 @@ }, { "name": "nesbot/carbon", - "version": "2.51.1", + "version": "2.57.0", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922" + "reference": "4a54375c21eea4811dbd1149fe6b246517554e78" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922", - "reference": "8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/4a54375c21eea4811dbd1149fe6b246517554e78", + "reference": "4a54375c21eea4811dbd1149fe6b246517554e78", "shasum": "" }, "require": { @@ -455,15 +464,16 @@ "php": "^7.1.8 || ^8.0", "symfony/polyfill-mbstring": "^1.0", "symfony/polyfill-php80": "^1.16", - "symfony/translation": "^3.4 || ^4.0 || ^5.0" + "symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0" }, "require-dev": { + "doctrine/dbal": "^2.0 || ^3.0", "doctrine/orm": "^2.7", - "friendsofphp/php-cs-fixer": "^2.14 || ^3.0", + "friendsofphp/php-cs-fixer": "^3.0", "kylekatarnls/multi-tester": "^2.0", "phpmd/phpmd": "^2.9", "phpstan/extension-installer": "^1.0", - "phpstan/phpstan": "^0.12.54", + "phpstan/phpstan": "^0.12.54 || ^1.0", "phpunit/phpunit": "^7.5.20 || ^8.5.14", "squizlabs/php_codesniffer": "^3.4" }, @@ -515,6 +525,7 @@ "time" ], "support": { + "docs": "https://carbon.nesbot.com/docs", "issues": "https://github.com/briannesbitt/Carbon/issues", "source": "https://github.com/briannesbitt/Carbon" }, @@ -528,7 +539,7 @@ "type": "tidelift" } ], - "time": "2021-07-28T13:16:28+00:00" + "time": "2022-02-13T18:13:33+00:00" }, { "name": "paragonie/random_compat", @@ -673,16 +684,16 @@ }, { "name": "phpmailer/phpmailer", - "version": "v6.5.0", + "version": "v6.6.0", "source": { "type": "git", "url": "https://github.com/PHPMailer/PHPMailer.git", - "reference": "a5b5c43e50b7fba655f793ad27303cd74c57363c" + "reference": "e43bac82edc26ca04b36143a48bde1c051cfd5b1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/a5b5c43e50b7fba655f793ad27303cd74c57363c", - "reference": "a5b5c43e50b7fba655f793ad27303cd74c57363c", + "url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/e43bac82edc26ca04b36143a48bde1c051cfd5b1", + "reference": "e43bac82edc26ca04b36143a48bde1c051cfd5b1", "shasum": "" }, "require": { @@ -694,10 +705,12 @@ "require-dev": { "dealerdirect/phpcodesniffer-composer-installer": "^0.7.0", "doctrine/annotations": "^1.2", + "php-parallel-lint/php-console-highlighter": "^0.5.0", + "php-parallel-lint/php-parallel-lint": "^1.3.1", "phpcompatibility/php-compatibility": "^9.3.5", "roave/security-advisories": "dev-latest", - "squizlabs/php_codesniffer": "^3.5.6", - "yoast/phpunit-polyfills": "^0.2.0" + "squizlabs/php_codesniffer": "^3.6.2", + "yoast/phpunit-polyfills": "^1.0.0" }, "suggest": { "ext-mbstring": "Needed to send email in multibyte encoding charset or decode encoded addresses", @@ -737,7 +750,7 @@ "description": "PHPMailer is a full-featured email creation and transfer class for PHP", "support": { "issues": "https://github.com/PHPMailer/PHPMailer/issues", - "source": "https://github.com/PHPMailer/PHPMailer/tree/v6.5.0" + "source": "https://github.com/PHPMailer/PHPMailer/tree/v6.6.0" }, "funding": [ { @@ -745,26 +758,31 @@ "type": "github" } ], - "time": "2021-06-16T14:33:43+00:00" + "time": "2022-02-28T15:31:21+00:00" }, { "name": "psr/container", - "version": "1.1.1", + "version": "2.0.2", "source": { "type": "git", "url": "https://github.com/php-fig/container.git", - "reference": "8622567409010282b7aeebe4bb841fe98b58dcaf" + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/8622567409010282b7aeebe4bb841fe98b58dcaf", - "reference": "8622567409010282b7aeebe4bb841fe98b58dcaf", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", "shasum": "" }, "require": { - "php": ">=7.2.0" + "php": ">=7.4.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, "autoload": { "psr-4": { "Psr\\Container\\": "src/" @@ -791,36 +809,36 @@ ], "support": { "issues": "https://github.com/php-fig/container/issues", - "source": "https://github.com/php-fig/container/tree/1.1.1" + "source": "https://github.com/php-fig/container/tree/2.0.2" }, - "time": "2021-03-05T17:36:06+00:00" + "time": "2021-11-05T16:47:00+00:00" }, { "name": "psr/log", - "version": "1.1.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "d49695b909c3b7628b6289db5479a1c204601f11" + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/d49695b909c3b7628b6289db5479a1c204601f11", - "reference": "d49695b909c3b7628b6289db5479a1c204601f11", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=8.0.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1.x-dev" + "dev-master": "3.x-dev" } }, "autoload": { "psr-4": { - "Psr\\Log\\": "Psr/Log/" + "Psr\\Log\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -841,31 +859,31 @@ "psr-3" ], "support": { - "source": "https://github.com/php-fig/log/tree/1.1.4" + "source": "https://github.com/php-fig/log/tree/3.0.0" }, - "time": "2021-05-03T11:20:27+00:00" + "time": "2021-07-14T16:46:02+00:00" }, { "name": "psr/simple-cache", - "version": "1.0.1", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/php-fig/simple-cache.git", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b" + "reference": "8707bf3cea6f710bf6ef05491234e3ab06f6432a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", + "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/8707bf3cea6f710bf6ef05491234e3ab06f6432a", + "reference": "8707bf3cea6f710bf6ef05491234e3ab06f6432a", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=8.0.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -880,7 +898,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common interfaces for simple caching", @@ -892,22 +910,22 @@ "simple-cache" ], "support": { - "source": "https://github.com/php-fig/simple-cache/tree/master" + "source": "https://github.com/php-fig/simple-cache/tree/2.0.0" }, - "time": "2017-10-23T01:57:42+00:00" + "time": "2021-10-29T13:22:09+00:00" }, { "name": "robthree/twofactorauth", - "version": "1.8.0", + "version": "1.8.1", "source": { "type": "git", "url": "https://github.com/RobThree/TwoFactorAuth.git", - "reference": "30a38627ae1e7c9399dae67e265063cd6ec5276c" + "reference": "5afcb45282f1c75562a48d479ecd1732c9bdb11b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/RobThree/TwoFactorAuth/zipball/30a38627ae1e7c9399dae67e265063cd6ec5276c", - "reference": "30a38627ae1e7c9399dae67e265063cd6ec5276c", + "url": "https://api.github.com/repos/RobThree/TwoFactorAuth/zipball/5afcb45282f1c75562a48d479ecd1732c9bdb11b", + "reference": "5afcb45282f1c75562a48d479ecd1732c9bdb11b", "shasum": "" }, "require": { @@ -964,7 +982,7 @@ "type": "github" } ], - "time": "2021-03-09T18:24:05+00:00" + "time": "2021-10-20T12:19:55+00:00" }, { "name": "soundasleep/html2text", @@ -1014,92 +1032,33 @@ "php", "text" ], + "support": { + "email": "support@jevon.org", + "issues": "https://github.com/soundasleep/html2text/issues", + "source": "https://github.com/soundasleep/html2text/tree/master" + }, "time": "2017-04-19T22:01:50+00:00" }, - { - "name": "symfony/deprecation-contracts", - "version": "v2.4.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "2.4-dev" - }, - "thanks": { - "name": "symfony/contracts", - "url": "https://github.com/symfony/contracts" - } - }, - "autoload": { - "files": [ - "function.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "A generic function and convention to trigger deprecation notices", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v2.4.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2021-03-23T23:28:01+00:00" - }, { "name": "symfony/polyfill-ctype", - "version": "v1.23.0", + "version": "v1.24.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce" + "reference": "30885182c981ab175d4d034db0f6f469898070ab" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/30885182c981ab175d4d034db0f6f469898070ab", + "reference": "30885182c981ab175d4d034db0f6f469898070ab", "shasum": "" }, "require": { "php": ">=7.1" }, + "provide": { + "ext-ctype": "*" + }, "suggest": { "ext-ctype": "For best performance" }, @@ -1114,12 +1073,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1144,7 +1103,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.24.0" }, "funding": [ { @@ -1160,25 +1119,28 @@ "type": "tidelift" } ], - "time": "2021-02-19T12:13:01+00:00" + "time": "2021-10-20T20:35:02+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.23.1", + "version": "v1.24.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6" + "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9174a3d80210dca8daa7f31fec659150bbeabfc6", - "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0abb51d2f102e00a4eefcf46ba7fec406d245825", + "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825", "shasum": "" }, "require": { "php": ">=7.1" }, + "provide": { + "ext-mbstring": "*" + }, "suggest": { "ext-mbstring": "For best performance" }, @@ -1193,12 +1155,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1224,7 +1186,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.24.0" }, "funding": [ { @@ -1240,20 +1202,20 @@ "type": "tidelift" } ], - "time": "2021-05-27T12:26:48+00:00" + "time": "2021-11-30T18:21:41+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.23.1", + "version": "v1.24.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "1100343ed1a92e3a38f9ae122fc0eb21602547be" + "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/1100343ed1a92e3a38f9ae122fc0eb21602547be", - "reference": "1100343ed1a92e3a38f9ae122fc0eb21602547be", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/57b712b08eddb97c762a8caa32c84e037892d2e9", + "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9", "shasum": "" }, "require": { @@ -1270,12 +1232,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php80\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -1307,7 +1269,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.24.0" }, "funding": [ { @@ -1323,50 +1285,50 @@ "type": "tidelift" } ], - "time": "2021-07-28T13:41:28+00:00" + "time": "2021-09-13T13:58:33+00:00" }, { "name": "symfony/translation", - "version": "v5.3.4", + "version": "v6.0.5", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "d89ad7292932c2699cbe4af98d72c5c6bbc504c1" + "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/d89ad7292932c2699cbe4af98d72c5c6bbc504c1", - "reference": "d89ad7292932c2699cbe4af98d72c5c6bbc504c1", + "url": "https://api.github.com/repos/symfony/translation/zipball/e69501c71107cc3146b32aaa45f4edd0c3427875", + "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/deprecation-contracts": "^2.1", + "php": ">=8.0.2", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php80": "^1.16", - "symfony/translation-contracts": "^2.3" + "symfony/translation-contracts": "^2.3|^3.0" }, "conflict": { - "symfony/config": "<4.4", - "symfony/dependency-injection": "<5.0", - "symfony/http-kernel": "<5.0", - "symfony/twig-bundle": "<5.0", - "symfony/yaml": "<4.4" + "symfony/config": "<5.4", + "symfony/console": "<5.4", + "symfony/dependency-injection": "<5.4", + "symfony/http-kernel": "<5.4", + "symfony/twig-bundle": "<5.4", + "symfony/yaml": "<5.4" }, "provide": { - "symfony/translation-implementation": "2.3" + "symfony/translation-implementation": "2.3|3.0" }, "require-dev": { "psr/log": "^1|^2|^3", - "symfony/config": "^4.4|^5.0", - "symfony/console": "^4.4|^5.0", - "symfony/dependency-injection": "^5.0", - "symfony/finder": "^4.4|^5.0", - "symfony/http-kernel": "^5.0", - "symfony/intl": "^4.4|^5.0", + "symfony/config": "^5.4|^6.0", + "symfony/console": "^5.4|^6.0", + "symfony/dependency-injection": "^5.4|^6.0", + "symfony/finder": "^5.4|^6.0", + "symfony/http-client-contracts": "^1.1|^2.0|^3.0", + "symfony/http-kernel": "^5.4|^6.0", + "symfony/intl": "^5.4|^6.0", "symfony/polyfill-intl-icu": "^1.21", - "symfony/service-contracts": "^1.1.2|^2", - "symfony/yaml": "^4.4|^5.0" + "symfony/service-contracts": "^1.1.2|^2|^3", + "symfony/yaml": "^5.4|^6.0" }, "suggest": { "psr/log-implementation": "To use logging capability in translator", @@ -1402,7 +1364,7 @@ "description": "Provides tools to internationalize your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/translation/tree/v5.3.4" + "source": "https://github.com/symfony/translation/tree/v6.0.5" }, "funding": [ { @@ -1418,24 +1380,24 @@ "type": "tidelift" } ], - "time": "2021-07-25T09:39:16+00:00" + "time": "2022-02-09T15:52:48+00:00" }, { "name": "symfony/translation-contracts", - "version": "v2.4.0", + "version": "v3.0.0", "source": { "type": "git", "url": "https://github.com/symfony/translation-contracts.git", - "reference": "95c812666f3e91db75385749fe219c5e494c7f95" + "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/95c812666f3e91db75385749fe219c5e494c7f95", - "reference": "95c812666f3e91db75385749fe219c5e494c7f95", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/1b6ea5a7442af5a12dba3dbd6d71034b5b234e77", + "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77", "shasum": "" }, "require": { - "php": ">=7.2.5" + "php": ">=8.0.2" }, "suggest": { "symfony/translation-implementation": "" @@ -1443,7 +1405,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "2.4-dev" + "dev-main": "3.0-dev" }, "thanks": { "name": "symfony/contracts", @@ -1480,7 +1442,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/translation-contracts/tree/v2.4.0" + "source": "https://github.com/symfony/translation-contracts/tree/v3.0.0" }, "funding": [ { @@ -1496,35 +1458,35 @@ "type": "tidelift" } ], - "time": "2021-03-23T23:28:01+00:00" + "time": "2021-09-07T12:43:40+00:00" }, { "name": "symfony/var-dumper", - "version": "v5.3.6", + "version": "v6.0.5", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0" + "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0", - "reference": "3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/60d6a756d5f485df5e6e40b337334848f79f61ce", + "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php80": "^1.16" + "php": ">=8.0.2", + "symfony/polyfill-mbstring": "~1.0" }, "conflict": { "phpunit/phpunit": "<5.4.3", - "symfony/console": "<4.4" + "symfony/console": "<5.4" }, "require-dev": { "ext-iconv": "*", - "symfony/console": "^4.4|^5.0", - "symfony/process": "^4.4|^5.0", + "symfony/console": "^5.4|^6.0", + "symfony/process": "^5.4|^6.0", + "symfony/uid": "^5.4|^6.0", "twig/twig": "^2.13|^3.0.4" }, "suggest": { @@ -1568,7 +1530,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v5.3.6" + "source": "https://github.com/symfony/var-dumper/tree/v6.0.5" }, "funding": [ { @@ -1584,25 +1546,25 @@ "type": "tidelift" } ], - "time": "2021-07-27T01:56:02+00:00" + "time": "2022-02-21T17:15:17+00:00" }, { "name": "tightenco/collect", - "version": "v8.34.0", + "version": "v8.83.2", "source": { "type": "git", "url": "https://github.com/tighten/collect.git", - "reference": "b069783ab0c547bb894ebcf8e7f6024bb401f9d2" + "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/tighten/collect/zipball/b069783ab0c547bb894ebcf8e7f6024bb401f9d2", - "reference": "b069783ab0c547bb894ebcf8e7f6024bb401f9d2", + "url": "https://api.github.com/repos/tighten/collect/zipball/d9c66d586ec2d216d8a31283d73f8df1400cc722", + "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722", "shasum": "" }, "require": { - "php": "^7.2|^8.0", - "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0" + "php": "^7.3|^8.0", + "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0 || ^6.0" }, "require-dev": { "mockery/mockery": "^1.0", @@ -1636,22 +1598,22 @@ ], "support": { "issues": "https://github.com/tighten/collect/issues", - "source": "https://github.com/tighten/collect/tree/v8.34.0" + "source": "https://github.com/tighten/collect/tree/v8.83.2" }, - "time": "2021-03-29T21:29:00+00:00" + "time": "2022-02-16T16:15:54+00:00" }, { "name": "twig/twig", - "version": "v3.3.2", + "version": "v3.3.8", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790" + "reference": "972d8604a92b7054828b539f2febb0211dd5945c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/21578f00e83d4a82ecfa3d50752b609f13de6790", - "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/972d8604a92b7054828b539f2febb0211dd5945c", + "reference": "972d8604a92b7054828b539f2febb0211dd5945c", "shasum": "" }, "require": { @@ -1661,7 +1623,7 @@ }, "require-dev": { "psr/container": "^1.0", - "symfony/phpunit-bridge": "^4.4.9|^5.0.9" + "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0" }, "type": "library", "extra": { @@ -1702,7 +1664,7 @@ ], "support": { "issues": "https://github.com/twigphp/Twig/issues", - "source": "https://github.com/twigphp/Twig/tree/v3.3.2" + "source": "https://github.com/twigphp/Twig/tree/v3.3.8" }, "funding": [ { @@ -1714,7 +1676,7 @@ "type": "tidelift" } ], - "time": "2021-05-16T12:14:13+00:00" + "time": "2022-02-04T06:59:48+00:00" }, { "name": "yubico/u2flib-server", @@ -1751,6 +1713,10 @@ ], "description": "Library for U2F implementation", "homepage": "https://developers.yubico.com/php-u2flib-server", + "support": { + "issues": "https://github.com/Yubico/php-u2flib-server/issues", + "source": "https://github.com/Yubico/php-u2flib-server/tree/1.0.2" + }, "time": "2018-09-07T08:16:44+00:00" } ], @@ -1762,5 +1728,5 @@ "prefer-lowest": false, "platform": [], "platform-dev": [], - "plugin-api-version": "2.1.0" + "plugin-api-version": "2.2.0" } diff --git a/data/web/inc/lib/vendor/bin/carbon b/data/web/inc/lib/vendor/bin/carbon deleted file mode 120000 index 0da48041..00000000 --- a/data/web/inc/lib/vendor/bin/carbon +++ /dev/null @@ -1 +0,0 @@ -../nesbot/carbon/bin/carbon \ No newline at end of file diff --git a/data/web/inc/lib/vendor/bin/carbon b/data/web/inc/lib/vendor/bin/carbon new file mode 100755 index 00000000..7b63379a --- /dev/null +++ b/data/web/inc/lib/vendor/bin/carbon @@ -0,0 +1,97 @@ +#!/usr/bin/env php +handle = fopen($opened_path, $mode); + $this->position = 0; + + // remove all traces of this stream wrapper once it has been used + stream_wrapper_unregister('composer-bin-proxy'); + + return (bool) $this->handle; + } + + public function stream_read($count) + { + $data = fread($this->handle, $count); + + if ($this->position === 0) { + $data = preg_replace('{^#!.*\r?\n}', '', $data); + } + + $this->position += strlen($data); + + return $data; + } + + public function stream_cast($castAs) + { + return $this->handle; + } + + public function stream_close() + { + fclose($this->handle); + } + + public function stream_lock($operation) + { + return $operation ? flock($this->handle, $operation) : true; + } + + public function stream_tell() + { + return $this->position; + } + + public function stream_eof() + { + return feof($this->handle); + } + + public function stream_stat() + { + return fstat($this->handle); + } + + public function stream_set_option($option, $arg1, $arg2) + { + return true; + } + } + } + + if (function_exists('stream_wrapper_register') && stream_wrapper_register('composer-bin-proxy', 'Composer\BinProxyWrapper')) { + include("composer-bin-proxy://" . __DIR__ . '/..'.'/nesbot/carbon/bin/carbon'); + exit(0); + } +} + +include __DIR__ . '/..'.'/nesbot/carbon/bin/carbon'; diff --git a/data/web/inc/lib/vendor/bin/minifycss b/data/web/inc/lib/vendor/bin/minifycss deleted file mode 120000 index 04f60a4b..00000000 --- a/data/web/inc/lib/vendor/bin/minifycss +++ /dev/null @@ -1 +0,0 @@ -../matthiasmullie/minify/bin/minifycss \ No newline at end of file diff --git a/data/web/inc/lib/vendor/bin/minifycss b/data/web/inc/lib/vendor/bin/minifycss new file mode 100755 index 00000000..0604366b --- /dev/null +++ b/data/web/inc/lib/vendor/bin/minifycss @@ -0,0 +1,97 @@ +#!/usr/bin/env php +handle = fopen($opened_path, $mode); + $this->position = 0; + + // remove all traces of this stream wrapper once it has been used + stream_wrapper_unregister('composer-bin-proxy'); + + return (bool) $this->handle; + } + + public function stream_read($count) + { + $data = fread($this->handle, $count); + + if ($this->position === 0) { + $data = preg_replace('{^#!.*\r?\n}', '', $data); + } + + $this->position += strlen($data); + + return $data; + } + + public function stream_cast($castAs) + { + return $this->handle; + } + + public function stream_close() + { + fclose($this->handle); + } + + public function stream_lock($operation) + { + return $operation ? flock($this->handle, $operation) : true; + } + + public function stream_tell() + { + return $this->position; + } + + public function stream_eof() + { + return feof($this->handle); + } + + public function stream_stat() + { + return fstat($this->handle); + } + + public function stream_set_option($option, $arg1, $arg2) + { + return true; + } + } + } + + if (function_exists('stream_wrapper_register') && stream_wrapper_register('composer-bin-proxy', 'Composer\BinProxyWrapper')) { + include("composer-bin-proxy://" . __DIR__ . '/..'.'/matthiasmullie/minify/bin/minifycss'); + exit(0); + } +} + +include __DIR__ . '/..'.'/matthiasmullie/minify/bin/minifycss'; diff --git a/data/web/inc/lib/vendor/bin/minifyjs b/data/web/inc/lib/vendor/bin/minifyjs deleted file mode 120000 index 61124467..00000000 --- a/data/web/inc/lib/vendor/bin/minifyjs +++ /dev/null @@ -1 +0,0 @@ -../matthiasmullie/minify/bin/minifyjs \ No newline at end of file diff --git a/data/web/inc/lib/vendor/bin/minifyjs b/data/web/inc/lib/vendor/bin/minifyjs new file mode 100755 index 00000000..f8ee9123 --- /dev/null +++ b/data/web/inc/lib/vendor/bin/minifyjs @@ -0,0 +1,97 @@ +#!/usr/bin/env php +handle = fopen($opened_path, $mode); + $this->position = 0; + + // remove all traces of this stream wrapper once it has been used + stream_wrapper_unregister('composer-bin-proxy'); + + return (bool) $this->handle; + } + + public function stream_read($count) + { + $data = fread($this->handle, $count); + + if ($this->position === 0) { + $data = preg_replace('{^#!.*\r?\n}', '', $data); + } + + $this->position += strlen($data); + + return $data; + } + + public function stream_cast($castAs) + { + return $this->handle; + } + + public function stream_close() + { + fclose($this->handle); + } + + public function stream_lock($operation) + { + return $operation ? flock($this->handle, $operation) : true; + } + + public function stream_tell() + { + return $this->position; + } + + public function stream_eof() + { + return feof($this->handle); + } + + public function stream_stat() + { + return fstat($this->handle); + } + + public function stream_set_option($option, $arg1, $arg2) + { + return true; + } + } + } + + if (function_exists('stream_wrapper_register') && stream_wrapper_register('composer-bin-proxy', 'Composer\BinProxyWrapper')) { + include("composer-bin-proxy://" . __DIR__ . '/..'.'/matthiasmullie/minify/bin/minifyjs'); + exit(0); + } +} + +include __DIR__ . '/..'.'/matthiasmullie/minify/bin/minifyjs'; diff --git a/data/web/inc/lib/vendor/bin/var-dump-server b/data/web/inc/lib/vendor/bin/var-dump-server deleted file mode 120000 index 6bd4e93d..00000000 --- a/data/web/inc/lib/vendor/bin/var-dump-server +++ /dev/null @@ -1 +0,0 @@ -../symfony/var-dumper/Resources/bin/var-dump-server \ No newline at end of file diff --git a/data/web/inc/lib/vendor/bin/var-dump-server b/data/web/inc/lib/vendor/bin/var-dump-server new file mode 100755 index 00000000..1eafd5d9 --- /dev/null +++ b/data/web/inc/lib/vendor/bin/var-dump-server @@ -0,0 +1,97 @@ +#!/usr/bin/env php +handle = fopen($opened_path, $mode); + $this->position = 0; + + // remove all traces of this stream wrapper once it has been used + stream_wrapper_unregister('composer-bin-proxy'); + + return (bool) $this->handle; + } + + public function stream_read($count) + { + $data = fread($this->handle, $count); + + if ($this->position === 0) { + $data = preg_replace('{^#!.*\r?\n}', '', $data); + } + + $this->position += strlen($data); + + return $data; + } + + public function stream_cast($castAs) + { + return $this->handle; + } + + public function stream_close() + { + fclose($this->handle); + } + + public function stream_lock($operation) + { + return $operation ? flock($this->handle, $operation) : true; + } + + public function stream_tell() + { + return $this->position; + } + + public function stream_eof() + { + return feof($this->handle); + } + + public function stream_stat() + { + return fstat($this->handle); + } + + public function stream_set_option($option, $arg1, $arg2) + { + return true; + } + } + } + + if (function_exists('stream_wrapper_register') && stream_wrapper_register('composer-bin-proxy', 'Composer\BinProxyWrapper')) { + include("composer-bin-proxy://" . __DIR__ . '/..'.'/symfony/var-dumper/Resources/bin/var-dump-server'); + exit(0); + } +} + +include __DIR__ . '/..'.'/symfony/var-dumper/Resources/bin/var-dump-server'; diff --git a/data/web/inc/lib/vendor/composer/ClassLoader.php b/data/web/inc/lib/vendor/composer/ClassLoader.php index 6d0c3f2d..afef3fa2 100644 --- a/data/web/inc/lib/vendor/composer/ClassLoader.php +++ b/data/web/inc/lib/vendor/composer/ClassLoader.php @@ -42,30 +42,75 @@ namespace Composer\Autoload; */ class ClassLoader { + /** @var ?string */ private $vendorDir; // PSR-4 + /** + * @var array[] + * @psalm-var array> + */ private $prefixLengthsPsr4 = array(); + /** + * @var array[] + * @psalm-var array> + */ private $prefixDirsPsr4 = array(); + /** + * @var array[] + * @psalm-var array + */ private $fallbackDirsPsr4 = array(); // PSR-0 + /** + * @var array[] + * @psalm-var array> + */ private $prefixesPsr0 = array(); + /** + * @var array[] + * @psalm-var array + */ private $fallbackDirsPsr0 = array(); + /** @var bool */ private $useIncludePath = false; + + /** + * @var string[] + * @psalm-var array + */ private $classMap = array(); + + /** @var bool */ private $classMapAuthoritative = false; + + /** + * @var bool[] + * @psalm-var array + */ private $missingClasses = array(); + + /** @var ?string */ private $apcuPrefix; + /** + * @var self[] + */ private static $registeredLoaders = array(); + /** + * @param ?string $vendorDir + */ public function __construct($vendorDir = null) { $this->vendorDir = $vendorDir; } + /** + * @return string[] + */ public function getPrefixes() { if (!empty($this->prefixesPsr0)) { @@ -75,28 +120,47 @@ class ClassLoader return array(); } + /** + * @return array[] + * @psalm-return array> + */ public function getPrefixesPsr4() { return $this->prefixDirsPsr4; } + /** + * @return array[] + * @psalm-return array + */ public function getFallbackDirs() { return $this->fallbackDirsPsr0; } + /** + * @return array[] + * @psalm-return array + */ public function getFallbackDirsPsr4() { return $this->fallbackDirsPsr4; } + /** + * @return string[] Array of classname => path + * @psalm-return array + */ public function getClassMap() { return $this->classMap; } /** - * @param array $classMap Class to filename map + * @param string[] $classMap Class to filename map + * @psalm-param array $classMap + * + * @return void */ public function addClassMap(array $classMap) { @@ -111,9 +175,11 @@ class ClassLoader * Registers a set of PSR-0 directories for a given prefix, either * appending or prepending to the ones previously set for this prefix. * - * @param string $prefix The prefix - * @param array|string $paths The PSR-0 root directories - * @param bool $prepend Whether to prepend the directories + * @param string $prefix The prefix + * @param string[]|string $paths The PSR-0 root directories + * @param bool $prepend Whether to prepend the directories + * + * @return void */ public function add($prefix, $paths, $prepend = false) { @@ -156,11 +222,13 @@ class ClassLoader * Registers a set of PSR-4 directories for a given namespace, either * appending or prepending to the ones previously set for this namespace. * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param array|string $paths The PSR-4 base directories - * @param bool $prepend Whether to prepend the directories + * @param string $prefix The prefix/namespace, with trailing '\\' + * @param string[]|string $paths The PSR-4 base directories + * @param bool $prepend Whether to prepend the directories * * @throws \InvalidArgumentException + * + * @return void */ public function addPsr4($prefix, $paths, $prepend = false) { @@ -204,8 +272,10 @@ class ClassLoader * Registers a set of PSR-0 directories for a given prefix, * replacing any others previously set for this prefix. * - * @param string $prefix The prefix - * @param array|string $paths The PSR-0 base directories + * @param string $prefix The prefix + * @param string[]|string $paths The PSR-0 base directories + * + * @return void */ public function set($prefix, $paths) { @@ -220,10 +290,12 @@ class ClassLoader * Registers a set of PSR-4 directories for a given namespace, * replacing any others previously set for this namespace. * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param array|string $paths The PSR-4 base directories + * @param string $prefix The prefix/namespace, with trailing '\\' + * @param string[]|string $paths The PSR-4 base directories * * @throws \InvalidArgumentException + * + * @return void */ public function setPsr4($prefix, $paths) { @@ -243,6 +315,8 @@ class ClassLoader * Turns on searching the include path for class files. * * @param bool $useIncludePath + * + * @return void */ public function setUseIncludePath($useIncludePath) { @@ -265,6 +339,8 @@ class ClassLoader * that have not been registered with the class map. * * @param bool $classMapAuthoritative + * + * @return void */ public function setClassMapAuthoritative($classMapAuthoritative) { @@ -285,6 +361,8 @@ class ClassLoader * APCu prefix to use to cache found/not-found classes, if the extension is enabled. * * @param string|null $apcuPrefix + * + * @return void */ public function setApcuPrefix($apcuPrefix) { @@ -305,6 +383,8 @@ class ClassLoader * Registers this instance as an autoloader. * * @param bool $prepend Whether to prepend the autoloader or not + * + * @return void */ public function register($prepend = false) { @@ -324,6 +404,8 @@ class ClassLoader /** * Unregisters this instance as an autoloader. + * + * @return void */ public function unregister() { @@ -403,6 +485,11 @@ class ClassLoader return self::$registeredLoaders; } + /** + * @param string $class + * @param string $ext + * @return string|false + */ private function findFileWithExtension($class, $ext) { // PSR-4 lookup @@ -474,6 +561,10 @@ class ClassLoader * Scope isolated include. * * Prevents access to $this/self from included files. + * + * @param string $file + * @return void + * @private */ function includeFile($file) { diff --git a/data/web/inc/lib/vendor/composer/InstalledVersions.php b/data/web/inc/lib/vendor/composer/InstalledVersions.php index b3a4e161..d50e0c9f 100644 --- a/data/web/inc/lib/vendor/composer/InstalledVersions.php +++ b/data/web/inc/lib/vendor/composer/InstalledVersions.php @@ -20,12 +20,25 @@ use Composer\Semver\VersionParser; * * See also https://getcomposer.org/doc/07-runtime.md#installed-versions * - * To require it's presence, you can require `composer-runtime-api ^2.0` + * To require its presence, you can require `composer-runtime-api ^2.0` */ class InstalledVersions { + /** + * @var mixed[]|null + * @psalm-var array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array}|array{}|null + */ private static $installed; + + /** + * @var bool|null + */ private static $canGetVendors; + + /** + * @var array[] + * @psalm-var array}> + */ private static $installedByVendor = array(); /** @@ -228,7 +241,7 @@ class InstalledVersions /** * @return array - * @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string} + * @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string} */ public static function getRootPackage() { @@ -242,7 +255,7 @@ class InstalledVersions * * @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect. * @return array[] - * @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}, versions: array} + * @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array} */ public static function getRawData() { @@ -265,7 +278,7 @@ class InstalledVersions * Returns the raw data of all installed.php which are currently loaded for custom implementations * * @return array[] - * @psalm-return list}> + * @psalm-return list}> */ public static function getAllRawData() { @@ -288,7 +301,7 @@ class InstalledVersions * @param array[] $data A vendor/composer/installed.php data set * @return void * - * @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}, versions: array} $data + * @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array} $data */ public static function reload($data) { @@ -298,7 +311,7 @@ class InstalledVersions /** * @return array[] - * @psalm-return list}> + * @psalm-return list}> */ private static function getInstalled() { diff --git a/data/web/inc/lib/vendor/composer/autoload_files.php b/data/web/inc/lib/vendor/composer/autoload_files.php index 183b68df..02f24c12 100644 --- a/data/web/inc/lib/vendor/composer/autoload_files.php +++ b/data/web/inc/lib/vendor/composer/autoload_files.php @@ -7,10 +7,9 @@ $baseDir = dirname($vendorDir); return array( '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php', - 'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php', - '6e3fae29631ef280660b3cdad06f25a8' => $vendorDir . '/symfony/deprecation-contracts/function.php', - 'a1105708a18b76903365ca1c4aa61b02' => $vendorDir . '/symfony/translation/Resources/functions.php', '320cde22f66dd4f5d3fd621d3e88b98f' => $vendorDir . '/symfony/polyfill-ctype/bootstrap.php', + 'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php', + 'a1105708a18b76903365ca1c4aa61b02' => $vendorDir . '/symfony/translation/Resources/functions.php', '667aeda72477189d0494fecd327c3641' => $vendorDir . '/symfony/var-dumper/Resources/functions/dump.php', 'fe62ba7e10580d903cc46d808b5961a4' => $vendorDir . '/tightenco/collect/src/Collect/Support/helpers.php', 'caf31cc6ec7cf2241cb6f12c226c3846' => $vendorDir . '/tightenco/collect/src/Collect/Support/alias.php', diff --git a/data/web/inc/lib/vendor/composer/autoload_psr4.php b/data/web/inc/lib/vendor/composer/autoload_psr4.php index 6e9d44e1..f75b7fa7 100644 --- a/data/web/inc/lib/vendor/composer/autoload_psr4.php +++ b/data/web/inc/lib/vendor/composer/autoload_psr4.php @@ -16,7 +16,7 @@ return array( 'Symfony\\Component\\Translation\\' => array($vendorDir . '/symfony/translation'), 'RobThree\\Auth\\' => array($vendorDir . '/robthree/twofactorauth/lib'), 'Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'), - 'Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'), + 'Psr\\Log\\' => array($vendorDir . '/psr/log/src'), 'Psr\\Container\\' => array($vendorDir . '/psr/container/src'), 'PhpMimeMailParser\\' => array($vendorDir . '/php-mime-mail-parser/php-mime-mail-parser/src'), 'PHPMailer\\PHPMailer\\' => array($vendorDir . '/phpmailer/phpmailer/src'), diff --git a/data/web/inc/lib/vendor/composer/autoload_real.php b/data/web/inc/lib/vendor/composer/autoload_real.php index 8a7686a4..250af557 100644 --- a/data/web/inc/lib/vendor/composer/autoload_real.php +++ b/data/web/inc/lib/vendor/composer/autoload_real.php @@ -65,11 +65,16 @@ class ComposerAutoloaderInit873464e4bd965a3168f133248b1b218b } } +/** + * @param string $fileIdentifier + * @param string $file + * @return void + */ function composerRequire873464e4bd965a3168f133248b1b218b($fileIdentifier, $file) { if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { - require $file; - $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; + + require $file; } } diff --git a/data/web/inc/lib/vendor/composer/autoload_static.php b/data/web/inc/lib/vendor/composer/autoload_static.php index 19aadb61..bdd03180 100644 --- a/data/web/inc/lib/vendor/composer/autoload_static.php +++ b/data/web/inc/lib/vendor/composer/autoload_static.php @@ -8,10 +8,9 @@ class ComposerStaticInit873464e4bd965a3168f133248b1b218b { public static $files = array ( '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php', - 'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php', - '6e3fae29631ef280660b3cdad06f25a8' => __DIR__ . '/..' . '/symfony/deprecation-contracts/function.php', - 'a1105708a18b76903365ca1c4aa61b02' => __DIR__ . '/..' . '/symfony/translation/Resources/functions.php', '320cde22f66dd4f5d3fd621d3e88b98f' => __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php', + 'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php', + 'a1105708a18b76903365ca1c4aa61b02' => __DIR__ . '/..' . '/symfony/translation/Resources/functions.php', '667aeda72477189d0494fecd327c3641' => __DIR__ . '/..' . '/symfony/var-dumper/Resources/functions/dump.php', 'fe62ba7e10580d903cc46d808b5961a4' => __DIR__ . '/..' . '/tightenco/collect/src/Collect/Support/helpers.php', 'caf31cc6ec7cf2241cb6f12c226c3846' => __DIR__ . '/..' . '/tightenco/collect/src/Collect/Support/alias.php', @@ -115,7 +114,7 @@ class ComposerStaticInit873464e4bd965a3168f133248b1b218b ), 'Psr\\Log\\' => array ( - 0 => __DIR__ . '/..' . '/psr/log/Psr/Log', + 0 => __DIR__ . '/..' . '/psr/log/src', ), 'Psr\\Container\\' => array ( diff --git a/data/web/inc/lib/vendor/composer/installed.json b/data/web/inc/lib/vendor/composer/installed.json index c5247040..a5cfe0e6 100644 --- a/data/web/inc/lib/vendor/composer/installed.json +++ b/data/web/inc/lib/vendor/composer/installed.json @@ -63,34 +63,35 @@ }, { "name": "ddeboer/imap", - "version": "1.12.1", - "version_normalized": "1.12.1.0", + "version": "1.13.1", + "version_normalized": "1.13.1.0", "source": { "type": "git", "url": "https://github.com/ddeboer/imap.git", - "reference": "dbed05ca67b93509345a820b2859de10c48948fb" + "reference": "8b772d04b1deadb5df13782fb78c4b648f77496e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ddeboer/imap/zipball/dbed05ca67b93509345a820b2859de10c48948fb", - "reference": "dbed05ca67b93509345a820b2859de10c48948fb", + "url": "https://api.github.com/repos/ddeboer/imap/zipball/8b772d04b1deadb5df13782fb78c4b648f77496e", + "reference": "8b772d04b1deadb5df13782fb78c4b648f77496e", "shasum": "" }, "require": { "ext-iconv": "*", "ext-imap": "*", "ext-mbstring": "*", - "php": "^7.4 || ^8.0" + "php": "^8.0.1" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.18.6", - "laminas/laminas-mail": "^2.14.0", - "phpstan/phpstan": "^0.12.84", - "phpstan/phpstan-phpunit": "^0.12.18", - "phpstan/phpstan-strict-rules": "^0.12.9", - "phpunit/phpunit": "^9.5.4" + "friendsofphp/php-cs-fixer": "^v3.4.0", + "laminas/laminas-mail": "^2.15.1", + "malukenho/mcbumpface": "^1.1.5", + "phpstan/phpstan": "^1.3.3", + "phpstan/phpstan-phpunit": "^1.0.0", + "phpstan/phpstan-strict-rules": "^1.1.0", + "phpunit/phpunit": "^9.5.11" }, - "time": "2021-04-27T08:38:46+00:00", + "time": "2022-01-10T10:53:05+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -124,7 +125,7 @@ ], "support": { "issues": "https://github.com/ddeboer/imap/issues", - "source": "https://github.com/ddeboer/imap/tree/1.12.1" + "source": "https://github.com/ddeboer/imap/tree/1.13.1" }, "funding": [ { @@ -140,35 +141,35 @@ }, { "name": "directorytree/ldaprecord", - "version": "v2.6.3", - "version_normalized": "2.6.3.0", + "version": "v2.10.1", + "version_normalized": "2.10.1.0", "source": { "type": "git", "url": "https://github.com/DirectoryTree/LdapRecord.git", - "reference": "5c93ec6d1ef458290825a8b0a148946dce7c1e7a" + "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/5c93ec6d1ef458290825a8b0a148946dce7c1e7a", - "reference": "5c93ec6d1ef458290825a8b0a148946dce7c1e7a", + "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/bf512d9af7a7b0e2ed7a666ab29cefdd027bee88", + "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88", "shasum": "" }, "require": { "ext-json": "*", "ext-ldap": "*", - "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0", + "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0|^9.0", "nesbot/carbon": "^1.0|^2.0", "php": ">=7.3", - "psr/log": "^1.0", - "psr/simple-cache": "^1.0", + "psr/log": "*", + "psr/simple-cache": "^1.0|^2.0", "tightenco/collect": "^5.6|^6.0|^7.0|^8.0" }, "require-dev": { "mockery/mockery": "^1.0", - "phpunit/phpunit": "^8.0", + "phpunit/phpunit": "^9.0", "spatie/ray": "^1.24" }, - "time": "2021-08-05T21:52:43+00:00", + "time": "2022-02-25T16:00:51+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -216,29 +217,29 @@ }, { "name": "illuminate/contracts", - "version": "v8.53.1", - "version_normalized": "8.53.1.0", + "version": "v9.3.0", + "version_normalized": "9.3.0.0", "source": { "type": "git", "url": "https://github.com/illuminate/contracts.git", - "reference": "504a34286a1b4c5421c43087d6bd4e176138f6fb" + "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/illuminate/contracts/zipball/504a34286a1b4c5421c43087d6bd4e176138f6fb", - "reference": "504a34286a1b4c5421c43087d6bd4e176138f6fb", + "url": "https://api.github.com/repos/illuminate/contracts/zipball/bf4b3c254c49d28157645d01e4883b5951b1e1d0", + "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0", "shasum": "" }, "require": { - "php": "^7.3|^8.0", - "psr/container": "^1.0", - "psr/simple-cache": "^1.0" + "php": "^8.0.2", + "psr/container": "^1.1.1|^2.0.1", + "psr/simple-cache": "^1.0|^2.0|^3.0" }, - "time": "2021-08-03T14:03:47+00:00", + "time": "2022-02-22T14:45:39+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "8.x-dev" + "dev-master": "9.x-dev" } }, "installation-source": "dist", @@ -453,17 +454,17 @@ }, { "name": "nesbot/carbon", - "version": "2.51.1", - "version_normalized": "2.51.1.0", + "version": "2.57.0", + "version_normalized": "2.57.0.0", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922" + "reference": "4a54375c21eea4811dbd1149fe6b246517554e78" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922", - "reference": "8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/4a54375c21eea4811dbd1149fe6b246517554e78", + "reference": "4a54375c21eea4811dbd1149fe6b246517554e78", "shasum": "" }, "require": { @@ -471,19 +472,20 @@ "php": "^7.1.8 || ^8.0", "symfony/polyfill-mbstring": "^1.0", "symfony/polyfill-php80": "^1.16", - "symfony/translation": "^3.4 || ^4.0 || ^5.0" + "symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0" }, "require-dev": { + "doctrine/dbal": "^2.0 || ^3.0", "doctrine/orm": "^2.7", - "friendsofphp/php-cs-fixer": "^2.14 || ^3.0", + "friendsofphp/php-cs-fixer": "^3.0", "kylekatarnls/multi-tester": "^2.0", "phpmd/phpmd": "^2.9", "phpstan/extension-installer": "^1.0", - "phpstan/phpstan": "^0.12.54", + "phpstan/phpstan": "^0.12.54 || ^1.0", "phpunit/phpunit": "^7.5.20 || ^8.5.14", "squizlabs/php_codesniffer": "^3.4" }, - "time": "2021-07-28T13:16:28+00:00", + "time": "2022-02-13T18:13:33+00:00", "bin": [ "bin/carbon" ], @@ -533,6 +535,7 @@ "time" ], "support": { + "docs": "https://carbon.nesbot.com/docs", "issues": "https://github.com/briannesbitt/Carbon/issues", "source": "https://github.com/briannesbitt/Carbon" }, @@ -697,17 +700,17 @@ }, { "name": "phpmailer/phpmailer", - "version": "v6.5.0", - "version_normalized": "6.5.0.0", + "version": "v6.6.0", + "version_normalized": "6.6.0.0", "source": { "type": "git", "url": "https://github.com/PHPMailer/PHPMailer.git", - "reference": "a5b5c43e50b7fba655f793ad27303cd74c57363c" + "reference": "e43bac82edc26ca04b36143a48bde1c051cfd5b1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/a5b5c43e50b7fba655f793ad27303cd74c57363c", - "reference": "a5b5c43e50b7fba655f793ad27303cd74c57363c", + "url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/e43bac82edc26ca04b36143a48bde1c051cfd5b1", + "reference": "e43bac82edc26ca04b36143a48bde1c051cfd5b1", "shasum": "" }, "require": { @@ -719,10 +722,12 @@ "require-dev": { "dealerdirect/phpcodesniffer-composer-installer": "^0.7.0", "doctrine/annotations": "^1.2", + "php-parallel-lint/php-console-highlighter": "^0.5.0", + "php-parallel-lint/php-parallel-lint": "^1.3.1", "phpcompatibility/php-compatibility": "^9.3.5", "roave/security-advisories": "dev-latest", - "squizlabs/php_codesniffer": "^3.5.6", - "yoast/phpunit-polyfills": "^0.2.0" + "squizlabs/php_codesniffer": "^3.6.2", + "yoast/phpunit-polyfills": "^1.0.0" }, "suggest": { "ext-mbstring": "Needed to send email in multibyte encoding charset or decode encoded addresses", @@ -732,7 +737,7 @@ "stevenmaguire/oauth2-microsoft": "Needed for Microsoft XOAUTH2 authentication", "symfony/polyfill-mbstring": "To support UTF-8 if the Mbstring PHP extension is not enabled (^1.2)" }, - "time": "2021-06-16T14:33:43+00:00", + "time": "2022-02-28T15:31:21+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -764,7 +769,7 @@ "description": "PHPMailer is a full-featured email creation and transfer class for PHP", "support": { "issues": "https://github.com/PHPMailer/PHPMailer/issues", - "source": "https://github.com/PHPMailer/PHPMailer/tree/v6.5.0" + "source": "https://github.com/PHPMailer/PHPMailer/tree/v6.6.0" }, "funding": [ { @@ -776,24 +781,29 @@ }, { "name": "psr/container", - "version": "1.1.1", - "version_normalized": "1.1.1.0", + "version": "2.0.2", + "version_normalized": "2.0.2.0", "source": { "type": "git", "url": "https://github.com/php-fig/container.git", - "reference": "8622567409010282b7aeebe4bb841fe98b58dcaf" + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/8622567409010282b7aeebe4bb841fe98b58dcaf", - "reference": "8622567409010282b7aeebe4bb841fe98b58dcaf", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", "shasum": "" }, "require": { - "php": ">=7.2.0" + "php": ">=7.4.0" }, - "time": "2021-03-05T17:36:06+00:00", + "time": "2021-11-05T16:47:00+00:00", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, "installation-source": "dist", "autoload": { "psr-4": { @@ -821,39 +831,39 @@ ], "support": { "issues": "https://github.com/php-fig/container/issues", - "source": "https://github.com/php-fig/container/tree/1.1.1" + "source": "https://github.com/php-fig/container/tree/2.0.2" }, "install-path": "../psr/container" }, { "name": "psr/log", - "version": "1.1.4", - "version_normalized": "1.1.4.0", + "version": "3.0.0", + "version_normalized": "3.0.0.0", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "d49695b909c3b7628b6289db5479a1c204601f11" + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/d49695b909c3b7628b6289db5479a1c204601f11", - "reference": "d49695b909c3b7628b6289db5479a1c204601f11", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=8.0.0" }, - "time": "2021-05-03T11:20:27+00:00", + "time": "2021-07-14T16:46:02+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1.x-dev" + "dev-master": "3.x-dev" } }, "installation-source": "dist", "autoload": { "psr-4": { - "Psr\\Log\\": "Psr/Log/" + "Psr\\Log\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -874,33 +884,33 @@ "psr-3" ], "support": { - "source": "https://github.com/php-fig/log/tree/1.1.4" + "source": "https://github.com/php-fig/log/tree/3.0.0" }, "install-path": "../psr/log" }, { "name": "psr/simple-cache", - "version": "1.0.1", - "version_normalized": "1.0.1.0", + "version": "2.0.0", + "version_normalized": "2.0.0.0", "source": { "type": "git", "url": "https://github.com/php-fig/simple-cache.git", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b" + "reference": "8707bf3cea6f710bf6ef05491234e3ab06f6432a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", + "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/8707bf3cea6f710bf6ef05491234e3ab06f6432a", + "reference": "8707bf3cea6f710bf6ef05491234e3ab06f6432a", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=8.0.0" }, - "time": "2017-10-23T01:57:42+00:00", + "time": "2021-10-29T13:22:09+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "installation-source": "dist", @@ -916,7 +926,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common interfaces for simple caching", @@ -928,23 +938,23 @@ "simple-cache" ], "support": { - "source": "https://github.com/php-fig/simple-cache/tree/master" + "source": "https://github.com/php-fig/simple-cache/tree/2.0.0" }, "install-path": "../psr/simple-cache" }, { "name": "robthree/twofactorauth", - "version": "1.8.0", - "version_normalized": "1.8.0.0", + "version": "1.8.1", + "version_normalized": "1.8.1.0", "source": { "type": "git", "url": "https://github.com/RobThree/TwoFactorAuth.git", - "reference": "30a38627ae1e7c9399dae67e265063cd6ec5276c" + "reference": "5afcb45282f1c75562a48d479ecd1732c9bdb11b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/RobThree/TwoFactorAuth/zipball/30a38627ae1e7c9399dae67e265063cd6ec5276c", - "reference": "30a38627ae1e7c9399dae67e265063cd6ec5276c", + "url": "https://api.github.com/repos/RobThree/TwoFactorAuth/zipball/5afcb45282f1c75562a48d479ecd1732c9bdb11b", + "reference": "5afcb45282f1c75562a48d479ecd1732c9bdb11b", "shasum": "" }, "require": { @@ -958,7 +968,7 @@ "bacon/bacon-qr-code": "Needed for BaconQrCodeProvider provider", "endroid/qr-code": "Needed for EndroidQrCodeProvider" }, - "time": "2021-03-09T18:24:05+00:00", + "time": "2021-10-20T12:19:55+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -1058,98 +1068,31 @@ ], "install-path": "../soundasleep/html2text" }, - { - "name": "symfony/deprecation-contracts", - "version": "v2.4.0", - "version_normalized": "2.4.0.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "time": "2021-03-23T23:28:01+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "2.4-dev" - }, - "thanks": { - "name": "symfony/contracts", - "url": "https://github.com/symfony/contracts" - } - }, - "installation-source": "dist", - "autoload": { - "files": [ - "function.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "A generic function and convention to trigger deprecation notices", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v2.4.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "install-path": "../symfony/deprecation-contracts" - }, { "name": "symfony/polyfill-ctype", - "version": "v1.23.0", - "version_normalized": "1.23.0.0", + "version": "v1.24.0", + "version_normalized": "1.24.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce" + "reference": "30885182c981ab175d4d034db0f6f469898070ab" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/30885182c981ab175d4d034db0f6f469898070ab", + "reference": "30885182c981ab175d4d034db0f6f469898070ab", "shasum": "" }, "require": { "php": ">=7.1" }, + "provide": { + "ext-ctype": "*" + }, "suggest": { "ext-ctype": "For best performance" }, - "time": "2021-02-19T12:13:01+00:00", + "time": "2021-10-20T20:35:02+00:00", "type": "library", "extra": { "branch-alias": { @@ -1162,12 +1105,12 @@ }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1192,7 +1135,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.24.0" }, "funding": [ { @@ -1212,26 +1155,29 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.23.1", - "version_normalized": "1.23.1.0", + "version": "v1.24.0", + "version_normalized": "1.24.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6" + "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9174a3d80210dca8daa7f31fec659150bbeabfc6", - "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0abb51d2f102e00a4eefcf46ba7fec406d245825", + "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825", "shasum": "" }, "require": { "php": ">=7.1" }, + "provide": { + "ext-mbstring": "*" + }, "suggest": { "ext-mbstring": "For best performance" }, - "time": "2021-05-27T12:26:48+00:00", + "time": "2021-11-30T18:21:41+00:00", "type": "library", "extra": { "branch-alias": { @@ -1244,12 +1190,12 @@ }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1275,7 +1221,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.24.0" }, "funding": [ { @@ -1295,23 +1241,23 @@ }, { "name": "symfony/polyfill-php80", - "version": "v1.23.1", - "version_normalized": "1.23.1.0", + "version": "v1.24.0", + "version_normalized": "1.24.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "1100343ed1a92e3a38f9ae122fc0eb21602547be" + "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/1100343ed1a92e3a38f9ae122fc0eb21602547be", - "reference": "1100343ed1a92e3a38f9ae122fc0eb21602547be", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/57b712b08eddb97c762a8caa32c84e037892d2e9", + "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9", "shasum": "" }, "require": { "php": ">=7.1" }, - "time": "2021-07-28T13:41:28+00:00", + "time": "2021-09-13T13:58:33+00:00", "type": "library", "extra": { "branch-alias": { @@ -1324,12 +1270,12 @@ }, "installation-source": "dist", "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php80\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -1361,7 +1307,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.24.0" }, "funding": [ { @@ -1381,54 +1327,54 @@ }, { "name": "symfony/translation", - "version": "v5.3.4", - "version_normalized": "5.3.4.0", + "version": "v6.0.5", + "version_normalized": "6.0.5.0", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "d89ad7292932c2699cbe4af98d72c5c6bbc504c1" + "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/d89ad7292932c2699cbe4af98d72c5c6bbc504c1", - "reference": "d89ad7292932c2699cbe4af98d72c5c6bbc504c1", + "url": "https://api.github.com/repos/symfony/translation/zipball/e69501c71107cc3146b32aaa45f4edd0c3427875", + "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/deprecation-contracts": "^2.1", + "php": ">=8.0.2", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php80": "^1.16", - "symfony/translation-contracts": "^2.3" + "symfony/translation-contracts": "^2.3|^3.0" }, "conflict": { - "symfony/config": "<4.4", - "symfony/dependency-injection": "<5.0", - "symfony/http-kernel": "<5.0", - "symfony/twig-bundle": "<5.0", - "symfony/yaml": "<4.4" + "symfony/config": "<5.4", + "symfony/console": "<5.4", + "symfony/dependency-injection": "<5.4", + "symfony/http-kernel": "<5.4", + "symfony/twig-bundle": "<5.4", + "symfony/yaml": "<5.4" }, "provide": { - "symfony/translation-implementation": "2.3" + "symfony/translation-implementation": "2.3|3.0" }, "require-dev": { "psr/log": "^1|^2|^3", - "symfony/config": "^4.4|^5.0", - "symfony/console": "^4.4|^5.0", - "symfony/dependency-injection": "^5.0", - "symfony/finder": "^4.4|^5.0", - "symfony/http-kernel": "^5.0", - "symfony/intl": "^4.4|^5.0", + "symfony/config": "^5.4|^6.0", + "symfony/console": "^5.4|^6.0", + "symfony/dependency-injection": "^5.4|^6.0", + "symfony/finder": "^5.4|^6.0", + "symfony/http-client-contracts": "^1.1|^2.0|^3.0", + "symfony/http-kernel": "^5.4|^6.0", + "symfony/intl": "^5.4|^6.0", "symfony/polyfill-intl-icu": "^1.21", - "symfony/service-contracts": "^1.1.2|^2", - "symfony/yaml": "^4.4|^5.0" + "symfony/service-contracts": "^1.1.2|^2|^3", + "symfony/yaml": "^5.4|^6.0" }, "suggest": { "psr/log-implementation": "To use logging capability in translator", "symfony/config": "", "symfony/yaml": "" }, - "time": "2021-07-25T09:39:16+00:00", + "time": "2022-02-09T15:52:48+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -1459,7 +1405,7 @@ "description": "Provides tools to internationalize your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/translation/tree/v5.3.4" + "source": "https://github.com/symfony/translation/tree/v6.0.5" }, "funding": [ { @@ -1479,30 +1425,30 @@ }, { "name": "symfony/translation-contracts", - "version": "v2.4.0", - "version_normalized": "2.4.0.0", + "version": "v3.0.0", + "version_normalized": "3.0.0.0", "source": { "type": "git", "url": "https://github.com/symfony/translation-contracts.git", - "reference": "95c812666f3e91db75385749fe219c5e494c7f95" + "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/95c812666f3e91db75385749fe219c5e494c7f95", - "reference": "95c812666f3e91db75385749fe219c5e494c7f95", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/1b6ea5a7442af5a12dba3dbd6d71034b5b234e77", + "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77", "shasum": "" }, "require": { - "php": ">=7.2.5" + "php": ">=8.0.2" }, "suggest": { "symfony/translation-implementation": "" }, - "time": "2021-03-23T23:28:01+00:00", + "time": "2021-09-07T12:43:40+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "2.4-dev" + "dev-main": "3.0-dev" }, "thanks": { "name": "symfony/contracts", @@ -1540,7 +1486,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/translation-contracts/tree/v2.4.0" + "source": "https://github.com/symfony/translation-contracts/tree/v3.0.0" }, "funding": [ { @@ -1560,32 +1506,32 @@ }, { "name": "symfony/var-dumper", - "version": "v5.3.6", - "version_normalized": "5.3.6.0", + "version": "v6.0.5", + "version_normalized": "6.0.5.0", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0" + "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0", - "reference": "3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/60d6a756d5f485df5e6e40b337334848f79f61ce", + "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php80": "^1.16" + "php": ">=8.0.2", + "symfony/polyfill-mbstring": "~1.0" }, "conflict": { "phpunit/phpunit": "<5.4.3", - "symfony/console": "<4.4" + "symfony/console": "<5.4" }, "require-dev": { "ext-iconv": "*", - "symfony/console": "^4.4|^5.0", - "symfony/process": "^4.4|^5.0", + "symfony/console": "^5.4|^6.0", + "symfony/process": "^5.4|^6.0", + "symfony/uid": "^5.4|^6.0", "twig/twig": "^2.13|^3.0.4" }, "suggest": { @@ -1593,7 +1539,7 @@ "ext-intl": "To show region name in time zone dump", "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script" }, - "time": "2021-07-27T01:56:02+00:00", + "time": "2022-02-21T17:15:17+00:00", "bin": [ "Resources/bin/var-dump-server" ], @@ -1631,7 +1577,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v5.3.6" + "source": "https://github.com/symfony/var-dumper/tree/v6.0.5" }, "funding": [ { @@ -1651,29 +1597,29 @@ }, { "name": "tightenco/collect", - "version": "v8.34.0", - "version_normalized": "8.34.0.0", + "version": "v8.83.2", + "version_normalized": "8.83.2.0", "source": { "type": "git", "url": "https://github.com/tighten/collect.git", - "reference": "b069783ab0c547bb894ebcf8e7f6024bb401f9d2" + "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/tighten/collect/zipball/b069783ab0c547bb894ebcf8e7f6024bb401f9d2", - "reference": "b069783ab0c547bb894ebcf8e7f6024bb401f9d2", + "url": "https://api.github.com/repos/tighten/collect/zipball/d9c66d586ec2d216d8a31283d73f8df1400cc722", + "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722", "shasum": "" }, "require": { - "php": "^7.2|^8.0", - "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0" + "php": "^7.3|^8.0", + "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0 || ^6.0" }, "require-dev": { "mockery/mockery": "^1.0", "nesbot/carbon": "^2.23.0", "phpunit/phpunit": "^8.3" }, - "time": "2021-03-29T21:29:00+00:00", + "time": "2022-02-16T16:15:54+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -1702,23 +1648,23 @@ ], "support": { "issues": "https://github.com/tighten/collect/issues", - "source": "https://github.com/tighten/collect/tree/v8.34.0" + "source": "https://github.com/tighten/collect/tree/v8.83.2" }, "install-path": "../tightenco/collect" }, { "name": "twig/twig", - "version": "v3.3.2", - "version_normalized": "3.3.2.0", + "version": "v3.3.8", + "version_normalized": "3.3.8.0", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790" + "reference": "972d8604a92b7054828b539f2febb0211dd5945c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/21578f00e83d4a82ecfa3d50752b609f13de6790", - "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/972d8604a92b7054828b539f2febb0211dd5945c", + "reference": "972d8604a92b7054828b539f2febb0211dd5945c", "shasum": "" }, "require": { @@ -1728,9 +1674,9 @@ }, "require-dev": { "psr/container": "^1.0", - "symfony/phpunit-bridge": "^4.4.9|^5.0.9" + "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0" }, - "time": "2021-05-16T12:14:13+00:00", + "time": "2022-02-04T06:59:48+00:00", "type": "library", "extra": { "branch-alias": { @@ -1771,7 +1717,7 @@ ], "support": { "issues": "https://github.com/twigphp/Twig/issues", - "source": "https://github.com/twigphp/Twig/tree/v3.3.2" + "source": "https://github.com/twigphp/Twig/tree/v3.3.8" }, "funding": [ { diff --git a/data/web/inc/lib/vendor/composer/installed.php b/data/web/inc/lib/vendor/composer/installed.php index cc343e04..9230ba25 100644 --- a/data/web/inc/lib/vendor/composer/installed.php +++ b/data/web/inc/lib/vendor/composer/installed.php @@ -1,22 +1,22 @@ array( - 'pretty_version' => 'dev-master', - 'version' => 'dev-master', + 'pretty_version' => '1.0.0+no-version-set', + 'version' => '1.0.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), - 'reference' => '1c2923a4ddd7f89b3cf38c9594db289b7dd756d3', + 'reference' => NULL, 'name' => '__root__', 'dev' => true, ), 'versions' => array( '__root__' => array( - 'pretty_version' => 'dev-master', - 'version' => 'dev-master', + 'pretty_version' => '1.0.0+no-version-set', + 'version' => '1.0.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), - 'reference' => '1c2923a4ddd7f89b3cf38c9594db289b7dd756d3', + 'reference' => NULL, 'dev_requirement' => false, ), 'bshaffer/oauth2-server-php' => array( @@ -29,21 +29,21 @@ 'dev_requirement' => false, ), 'ddeboer/imap' => array( - 'pretty_version' => '1.12.1', - 'version' => '1.12.1.0', + 'pretty_version' => '1.13.1', + 'version' => '1.13.1.0', 'type' => 'library', 'install_path' => __DIR__ . '/../ddeboer/imap', 'aliases' => array(), - 'reference' => 'dbed05ca67b93509345a820b2859de10c48948fb', + 'reference' => '8b772d04b1deadb5df13782fb78c4b648f77496e', 'dev_requirement' => false, ), 'directorytree/ldaprecord' => array( - 'pretty_version' => 'v2.6.3', - 'version' => '2.6.3.0', + 'pretty_version' => 'v2.10.1', + 'version' => '2.10.1.0', 'type' => 'library', 'install_path' => __DIR__ . '/../directorytree/ldaprecord', 'aliases' => array(), - 'reference' => '5c93ec6d1ef458290825a8b0a148946dce7c1e7a', + 'reference' => 'bf512d9af7a7b0e2ed7a666ab29cefdd027bee88', 'dev_requirement' => false, ), 'exorus/php-mime-mail-parser' => array( @@ -53,12 +53,12 @@ ), ), 'illuminate/contracts' => array( - 'pretty_version' => 'v8.53.1', - 'version' => '8.53.1.0', + 'pretty_version' => 'v9.3.0', + 'version' => '9.3.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../illuminate/contracts', 'aliases' => array(), - 'reference' => '504a34286a1b4c5421c43087d6bd4e176138f6fb', + 'reference' => 'bf4b3c254c49d28157645d01e4883b5951b1e1d0', 'dev_requirement' => false, ), 'matthiasmullie/minify' => array( @@ -95,12 +95,12 @@ 'dev_requirement' => false, ), 'nesbot/carbon' => array( - 'pretty_version' => '2.51.1', - 'version' => '2.51.1.0', + 'pretty_version' => '2.57.0', + 'version' => '2.57.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../nesbot/carbon', 'aliases' => array(), - 'reference' => '8619c299d1e0d4b344e1f98ca07a1ce2cfbf1922', + 'reference' => '4a54375c21eea4811dbd1149fe6b246517554e78', 'dev_requirement' => false, ), 'paragonie/random_compat' => array( @@ -122,48 +122,48 @@ 'dev_requirement' => false, ), 'phpmailer/phpmailer' => array( - 'pretty_version' => 'v6.5.0', - 'version' => '6.5.0.0', + 'pretty_version' => 'v6.6.0', + 'version' => '6.6.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../phpmailer/phpmailer', 'aliases' => array(), - 'reference' => 'a5b5c43e50b7fba655f793ad27303cd74c57363c', + 'reference' => 'e43bac82edc26ca04b36143a48bde1c051cfd5b1', 'dev_requirement' => false, ), 'psr/container' => array( - 'pretty_version' => '1.1.1', - 'version' => '1.1.1.0', + 'pretty_version' => '2.0.2', + 'version' => '2.0.2.0', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/container', 'aliases' => array(), - 'reference' => '8622567409010282b7aeebe4bb841fe98b58dcaf', + 'reference' => 'c71ecc56dfe541dbd90c5360474fbc405f8d5963', 'dev_requirement' => false, ), 'psr/log' => array( - 'pretty_version' => '1.1.4', - 'version' => '1.1.4.0', + 'pretty_version' => '3.0.0', + 'version' => '3.0.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/log', 'aliases' => array(), - 'reference' => 'd49695b909c3b7628b6289db5479a1c204601f11', + 'reference' => 'fe5ea303b0887d5caefd3d431c3e61ad47037001', 'dev_requirement' => false, ), 'psr/simple-cache' => array( - 'pretty_version' => '1.0.1', - 'version' => '1.0.1.0', + 'pretty_version' => '2.0.0', + 'version' => '2.0.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/simple-cache', 'aliases' => array(), - 'reference' => '408d5eafb83c57f6365a3ca330ff23aa4a5fa39b', + 'reference' => '8707bf3cea6f710bf6ef05491234e3ab06f6432a', 'dev_requirement' => false, ), 'robthree/twofactorauth' => array( - 'pretty_version' => '1.8.0', - 'version' => '1.8.0.0', + 'pretty_version' => '1.8.1', + 'version' => '1.8.1.0', 'type' => 'library', 'install_path' => __DIR__ . '/../robthree/twofactorauth', 'aliases' => array(), - 'reference' => '30a38627ae1e7c9399dae67e265063cd6ec5276c', + 'reference' => '5afcb45282f1c75562a48d479ecd1732c9bdb11b', 'dev_requirement' => false, ), 'soundasleep/html2text' => array( @@ -175,91 +175,82 @@ 'reference' => 'cdb89f6ffa2c4cc78f8ed9ea6ee0594a9133ccad', 'dev_requirement' => false, ), - 'symfony/deprecation-contracts' => array( - 'pretty_version' => 'v2.4.0', - 'version' => '2.4.0.0', - 'type' => 'library', - 'install_path' => __DIR__ . '/../symfony/deprecation-contracts', - 'aliases' => array(), - 'reference' => '5f38c8804a9e97d23e0c8d63341088cd8a22d627', - 'dev_requirement' => false, - ), 'symfony/polyfill-ctype' => array( - 'pretty_version' => 'v1.23.0', - 'version' => '1.23.0.0', + 'pretty_version' => 'v1.24.0', + 'version' => '1.24.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-ctype', 'aliases' => array(), - 'reference' => '46cd95797e9df938fdd2b03693b5fca5e64b01ce', + 'reference' => '30885182c981ab175d4d034db0f6f469898070ab', 'dev_requirement' => false, ), 'symfony/polyfill-mbstring' => array( - 'pretty_version' => 'v1.23.1', - 'version' => '1.23.1.0', + 'pretty_version' => 'v1.24.0', + 'version' => '1.24.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-mbstring', 'aliases' => array(), - 'reference' => '9174a3d80210dca8daa7f31fec659150bbeabfc6', + 'reference' => '0abb51d2f102e00a4eefcf46ba7fec406d245825', 'dev_requirement' => false, ), 'symfony/polyfill-php80' => array( - 'pretty_version' => 'v1.23.1', - 'version' => '1.23.1.0', + 'pretty_version' => 'v1.24.0', + 'version' => '1.24.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/polyfill-php80', 'aliases' => array(), - 'reference' => '1100343ed1a92e3a38f9ae122fc0eb21602547be', + 'reference' => '57b712b08eddb97c762a8caa32c84e037892d2e9', 'dev_requirement' => false, ), 'symfony/translation' => array( - 'pretty_version' => 'v5.3.4', - 'version' => '5.3.4.0', + 'pretty_version' => 'v6.0.5', + 'version' => '6.0.5.0', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/translation', 'aliases' => array(), - 'reference' => 'd89ad7292932c2699cbe4af98d72c5c6bbc504c1', + 'reference' => 'e69501c71107cc3146b32aaa45f4edd0c3427875', 'dev_requirement' => false, ), 'symfony/translation-contracts' => array( - 'pretty_version' => 'v2.4.0', - 'version' => '2.4.0.0', + 'pretty_version' => 'v3.0.0', + 'version' => '3.0.0.0', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/translation-contracts', 'aliases' => array(), - 'reference' => '95c812666f3e91db75385749fe219c5e494c7f95', + 'reference' => '1b6ea5a7442af5a12dba3dbd6d71034b5b234e77', 'dev_requirement' => false, ), 'symfony/translation-implementation' => array( 'dev_requirement' => false, 'provided' => array( - 0 => '2.3', + 0 => '2.3|3.0', ), ), 'symfony/var-dumper' => array( - 'pretty_version' => 'v5.3.6', - 'version' => '5.3.6.0', + 'pretty_version' => 'v6.0.5', + 'version' => '6.0.5.0', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/var-dumper', 'aliases' => array(), - 'reference' => '3dd8ddd1e260e58ecc61bb78da3b6584b3bfcba0', + 'reference' => '60d6a756d5f485df5e6e40b337334848f79f61ce', 'dev_requirement' => false, ), 'tightenco/collect' => array( - 'pretty_version' => 'v8.34.0', - 'version' => '8.34.0.0', + 'pretty_version' => 'v8.83.2', + 'version' => '8.83.2.0', 'type' => 'library', 'install_path' => __DIR__ . '/../tightenco/collect', 'aliases' => array(), - 'reference' => 'b069783ab0c547bb894ebcf8e7f6024bb401f9d2', + 'reference' => 'd9c66d586ec2d216d8a31283d73f8df1400cc722', 'dev_requirement' => false, ), 'twig/twig' => array( - 'pretty_version' => 'v3.3.2', - 'version' => '3.3.2.0', + 'pretty_version' => 'v3.3.8', + 'version' => '3.3.8.0', 'type' => 'library', 'install_path' => __DIR__ . '/../twig/twig', 'aliases' => array(), - 'reference' => '21578f00e83d4a82ecfa3d50752b609f13de6790', + 'reference' => '972d8604a92b7054828b539f2febb0211dd5945c', 'dev_requirement' => false, ), 'yubico/u2flib-server' => array( diff --git a/data/web/inc/lib/vendor/composer/platform_check.php b/data/web/inc/lib/vendor/composer/platform_check.php index 580fa960..b168ddd5 100644 --- a/data/web/inc/lib/vendor/composer/platform_check.php +++ b/data/web/inc/lib/vendor/composer/platform_check.php @@ -4,8 +4,8 @@ $issues = array(); -if (!(PHP_VERSION_ID >= 70400)) { - $issues[] = 'Your Composer dependencies require a PHP version ">= 7.4.0". You are running ' . PHP_VERSION . '.'; +if (!(PHP_VERSION_ID >= 80002)) { + $issues[] = 'Your Composer dependencies require a PHP version ">= 8.0.2". You are running ' . PHP_VERSION . '.'; } if ($issues) { diff --git a/data/web/inc/lib/vendor/ddeboer/imap/.php-cs-fixer.php b/data/web/inc/lib/vendor/ddeboer/imap/.php-cs-fixer.php new file mode 100644 index 00000000..22b4ada2 --- /dev/null +++ b/data/web/inc/lib/vendor/ddeboer/imap/.php-cs-fixer.php @@ -0,0 +1,73 @@ +setRiskyAllowed(true) + ->setRules([ + '@DoctrineAnnotation' => true, + '@Symfony' => true, + '@Symfony:risky' => true, + '@PHPUnit75Migration:risky' => true, + '@PHP71Migration' => true, + '@PHP70Migration:risky' => true, // @TODO with next major version + 'align_multiline_comment' => ['comment_type' => 'all_multiline'], + 'array_indentation' => true, + 'array_syntax' => ['syntax' => 'short'], + 'binary_operator_spaces' => ['default' => 'align_single_space'], + 'blank_line_before_statement' => true, + 'class_definition' => ['single_item_single_line' => true], + 'compact_nullable_typehint' => true, + 'concat_space' => ['spacing' => 'one'], + 'echo_tag_syntax' => ['format' => 'long'], + 'error_suppression' => false, + 'escape_implicit_backslashes' => true, + 'explicit_indirect_variable' => true, + 'explicit_string_variable' => true, + 'fully_qualified_strict_types' => true, + 'heredoc_to_nowdoc' => true, + 'list_syntax' => ['syntax' => 'long'], + 'method_argument_space' => ['on_multiline' => 'ensure_fully_multiline'], + 'method_chaining_indentation' => true, + 'multiline_comment_opening_closing' => true, + 'multiline_whitespace_before_semicolons' => ['strategy' => 'new_line_for_chained_calls'], + 'native_constant_invocation' => true, + 'native_function_invocation' => ['include' => ['@internal']], + 'no_alternative_syntax' => true, + 'no_break_comment' => true, + 'no_extra_blank_lines' => ['tokens' => ['break', 'continue', 'extra', 'return', 'throw', 'use', 'parenthesis_brace_block', 'square_brace_block', 'curly_brace_block']], + 'no_null_property_initialization' => true, + 'no_php4_constructor' => true, + 'no_superfluous_elseif' => true, + 'no_unneeded_curly_braces' => true, + 'no_unneeded_final_method' => true, + 'no_unreachable_default_argument_value' => true, + 'no_useless_else' => true, + 'no_useless_return' => true, + 'ordered_imports' => true, + 'php_unit_method_casing' => true, + 'php_unit_set_up_tear_down_visibility' => true, + 'php_unit_strict' => true, + 'php_unit_test_annotation' => true, + 'php_unit_test_case_static_method_calls' => true, + 'php_unit_test_class_requires_covers' => false, + 'phpdoc_add_missing_param_annotation' => true, + 'phpdoc_order' => true, + 'phpdoc_order_by_value' => true, + 'phpdoc_types_order' => true, + 'random_api_migration' => true, + 'semicolon_after_instruction' => true, + 'simplified_null_return' => true, + 'single_line_comment_style' => true, + 'single_line_throw' => false, + 'space_after_semicolon' => true, + 'static_lambda' => true, + 'strict_comparison' => true, + 'string_line_ending' => true, + ]) + ->setFinder( + PhpCsFixer\Finder::create() + ->in(__DIR__ . '/src') + ->in(__DIR__ . '/tests') + ) +; diff --git a/data/web/inc/lib/vendor/ddeboer/imap/composer.json b/data/web/inc/lib/vendor/ddeboer/imap/composer.json index 92b4a07f..0bcf72af 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/composer.json +++ b/data/web/inc/lib/vendor/ddeboer/imap/composer.json @@ -1,12 +1,12 @@ { "name": "ddeboer/imap", "description": "Object-oriented IMAP for PHP", + "license": "MIT", "keywords": [ "email", "mail", "imap" ], - "license": "MIT", "authors": [ { "name": "David de Boer", @@ -22,18 +22,19 @@ } ], "require": { - "php": "^7.4 || ^8.0", + "php": "^8.0.1", "ext-iconv": "*", "ext-imap": "*", "ext-mbstring": "*" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.18.6", - "laminas/laminas-mail": "^2.14.0", - "phpstan/phpstan": "^0.12.84", - "phpstan/phpstan-phpunit": "^0.12.18", - "phpstan/phpstan-strict-rules": "^0.12.9", - "phpunit/phpunit": "^9.5.4" + "friendsofphp/php-cs-fixer": "^v3.4.0", + "laminas/laminas-mail": "^2.15.1", + "malukenho/mcbumpface": "^1.1.5", + "phpstan/phpstan": "^1.3.3", + "phpstan/phpstan-phpunit": "^1.0.0", + "phpstan/phpstan-strict-rules": "^1.1.0", + "phpunit/phpunit": "^9.5.11" }, "autoload": { "psr-4": { @@ -44,5 +45,10 @@ "psr-4": { "Ddeboer\\Imap\\Tests\\": "tests/" } + }, + "config": { + "allow-plugins": { + "malukenho/mcbumpface": true + } } } diff --git a/data/web/inc/lib/vendor/ddeboer/imap/src/Connection.php b/data/web/inc/lib/vendor/ddeboer/imap/src/Connection.php index d9f2bb68..9f5ef90f 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/src/Connection.php +++ b/data/web/inc/lib/vendor/ddeboer/imap/src/Connection.php @@ -117,6 +117,7 @@ final class Connection implements ConnectionInterface return new Mailbox($this->resource, $name, $this->mailboxNames[$name]); } + #[\ReturnTypeWillChange] public function count() { $return = \imap_num_msg($this->resource->getStream()); diff --git a/data/web/inc/lib/vendor/ddeboer/imap/src/ImapResource.php b/data/web/inc/lib/vendor/ddeboer/imap/src/ImapResource.php index 123ea239..60d348a9 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/src/ImapResource.php +++ b/data/web/inc/lib/vendor/ddeboer/imap/src/ImapResource.php @@ -6,6 +6,7 @@ namespace Ddeboer\Imap; use Ddeboer\Imap\Exception\InvalidResourceException; use Ddeboer\Imap\Exception\ReopenMailboxException; +use IMAP\Connection; /** * An imap resource stream. @@ -22,7 +23,7 @@ final class ImapResource implements ImapResourceInterface /** * Constructor. * - * @param resource $resource + * @param Connection|resource $resource */ public function __construct($resource, MailboxInterface $mailbox = null) { @@ -32,7 +33,10 @@ final class ImapResource implements ImapResourceInterface public function getStream() { - if (false === \is_resource($this->resource) || 'imap' !== \get_resource_type($this->resource)) { + if ( + !$this->resource instanceof Connection + && (false === \is_resource($this->resource) || 'imap' !== \get_resource_type($this->resource)) + ) { throw new InvalidResourceException('Supplied resource is not a valid imap resource'); } @@ -55,8 +59,14 @@ final class ImapResource implements ImapResourceInterface return; } + \set_error_handler(static function (): bool { + return true; + }); + \imap_reopen($this->resource, $this->mailbox->getFullEncodedName()); + \restore_error_handler(); + if (self::isMailboxOpen($this->mailbox, $this->resource)) { return; } diff --git a/data/web/inc/lib/vendor/ddeboer/imap/src/Mailbox.php b/data/web/inc/lib/vendor/ddeboer/imap/src/Mailbox.php index 2f77799f..38823fee 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/src/Mailbox.php +++ b/data/web/inc/lib/vendor/ddeboer/imap/src/Mailbox.php @@ -64,6 +64,7 @@ final class Mailbox implements MailboxInterface return $this->info->delimiter; } + #[\ReturnTypeWillChange] public function count() { $return = \imap_num_msg($this->resource->getStream()); diff --git a/data/web/inc/lib/vendor/ddeboer/imap/src/Message/AbstractPart.php b/data/web/inc/lib/vendor/ddeboer/imap/src/Message/AbstractPart.php index 0ab0ca58..0647133c 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/src/Message/AbstractPart.php +++ b/data/web/inc/lib/vendor/ddeboer/imap/src/Message/AbstractPart.php @@ -268,6 +268,7 @@ abstract class AbstractPart implements PartInterface * * @return mixed */ + #[\ReturnTypeWillChange] final public function current() { $this->lazyParseStructure(); @@ -275,11 +276,13 @@ abstract class AbstractPart implements PartInterface return $this->parts[$this->key]; } + #[\ReturnTypeWillChange] final public function getChildren() { return $this->current(); } + #[\ReturnTypeWillChange] final public function hasChildren() { $this->lazyParseStructure(); @@ -290,21 +293,25 @@ abstract class AbstractPart implements PartInterface /** * @return int */ + #[\ReturnTypeWillChange] final public function key() { return $this->key; } + #[\ReturnTypeWillChange] final public function next() { ++$this->key; } + #[\ReturnTypeWillChange] final public function rewind() { $this->key = 0; } + #[\ReturnTypeWillChange] final public function valid() { $this->lazyParseStructure(); diff --git a/data/web/inc/lib/vendor/ddeboer/imap/src/Message/EmailAddress.php b/data/web/inc/lib/vendor/ddeboer/imap/src/Message/EmailAddress.php index 9f60fb14..4833487d 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/src/Message/EmailAddress.php +++ b/data/web/inc/lib/vendor/ddeboer/imap/src/Message/EmailAddress.php @@ -19,6 +19,7 @@ final class EmailAddress $this->mailbox = $mailbox; $this->hostname = $hostname; $this->name = $name; + $this->address = null; if (null !== $hostname) { $this->address = $mailbox . '@' . $hostname; diff --git a/data/web/inc/lib/vendor/ddeboer/imap/src/MessageIteratorInterface.php b/data/web/inc/lib/vendor/ddeboer/imap/src/MessageIteratorInterface.php index 36a79438..736084b1 100644 --- a/data/web/inc/lib/vendor/ddeboer/imap/src/MessageIteratorInterface.php +++ b/data/web/inc/lib/vendor/ddeboer/imap/src/MessageIteratorInterface.php @@ -9,7 +9,7 @@ use Ddeboer\Imap\Message\PartInterface; /** * @extends \Iterator */ -interface MessageIteratorInterface extends \Iterator +interface MessageIteratorInterface extends \Iterator, \Countable { /** * Get current message. diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml b/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml index ba002183..8c7b5314 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml @@ -13,7 +13,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, windows-latest] - php: [8.0, 7.4, 7.3] + php: [8.1, 8.0, 7.4, 7.3] name: ${{ matrix.os }} - P${{ matrix.php }} @@ -39,3 +39,40 @@ jobs: - name: Execute tests run: vendor/bin/phpunit + + run-analysis: + runs-on: ${{ matrix.os }} + name: Static code analysis (PHP ${{ matrix.php }}) + + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + php: [8.0] + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Cache dependencies + uses: actions/cache@v2 + with: + path: ~/.composer/cache/files + key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }} + + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php }} + extensions: ldap, json + coverage: none + tools: psalm + + - name: Validate composer.json + run: composer validate + + - name: Install dependencies + run: composer update --prefer-dist --no-interaction + + - name: Run Psalm + run: psalm diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/.gitignore b/data/web/inc/lib/vendor/directorytree/ldaprecord/.gitignore index d5389fd6..e288894f 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/.gitignore +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/.gitignore @@ -1,5 +1,6 @@ vendor composer.lock +psalm.phar .php_cs.cache .phpunit.result.cache .php-cs-fixer.cache \ No newline at end of file diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml b/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml index c7740212..9f5e38cf 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml @@ -1,4 +1,8 @@ preset: laravel enabled: - phpdoc_align + - phpdoc_separation - unalign_double_arrow +disabled: + - laravel_phpdoc_alignment + - laravel_phpdoc_separation diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json b/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json index 2e995d9d..35c60576 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json @@ -32,19 +32,21 @@ "php": ">=7.3", "ext-ldap": "*", "ext-json": "*", - "psr/log": "^1.0", - "psr/simple-cache": "^1.0", + "psr/log": "*", + "psr/simple-cache": "^1.0|^2.0", "nesbot/carbon": "^1.0|^2.0", "tightenco/collect": "^5.6|^6.0|^7.0|^8.0", - "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0" + "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0|^9.0" }, "require-dev": { - "phpunit/phpunit": "^8.0", + "phpunit/phpunit": "^9.0", "mockery/mockery": "^1.0", "spatie/ray": "^1.24" }, "archive": { - "exclude": ["/tests"] + "exclude": [ + "/tests" + ] }, "autoload": { "psr-4": { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md b/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md index 08ecd9e7..505d6992 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md @@ -92,3 +92,13 @@ We've all been there -- accidentally deleting a user or group in Active Director

If you discover a security vulnerability within LdapRecord, please send an e-mail to Steve Bauman via steven_bauman@outlook.com.

All security vulnerabilities will be promptly addressed.

+ +--- + +

Credits

+ +

This package is directly inspired from Laravel's Eloquent, and most features are direct ports to an LDAP equivalent.

+ +

I am forever grateful for the work Taylor Otwell has produced.

+ +

If you can, support his work by purchasing a sponsorship, or one of his many Laravel based services.

diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php index 696cc40d..d41af156 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php @@ -54,10 +54,10 @@ class Guard * @param string $password * @param bool $stayBound * + * @return bool + * * @throws UsernameRequiredException * @throws PasswordRequiredException - * - * @return bool */ public function attempt($username, $password, $stayBound = false) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php index 1dcdd1a1..d1124bfc 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php @@ -124,9 +124,9 @@ class DomainConfiguration * * @param string $key * - * @throws ConfigurationException When the option specified does not exist. - * * @return mixed + * + * @throws ConfigurationException When the option specified does not exist. */ public function get($key) { @@ -155,9 +155,9 @@ class DomainConfiguration * @param string $key * @param mixed $value * - * @throws ConfigurationException When an option value given is an invalid type. - * * @return bool + * + * @throws ConfigurationException When an option value given is an invalid type. */ protected function validate($key, $value) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php index 908a6395..de2f13f5 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php @@ -49,9 +49,9 @@ abstract class Validator /** * Validate the configuration value. * - * @throws ConfigurationException - * * @return bool + * + * @throws ConfigurationException */ public function validate() { @@ -65,9 +65,9 @@ abstract class Validator /** * Throw a configuration exception. * - * @throws ConfigurationException - * * @return void + * + * @throws ConfigurationException */ protected function fail() { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php index 8ba0ef1d..d429aa46 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php @@ -111,9 +111,9 @@ class Connection * * @param array $config * - * @throws Configuration\ConfigurationException - * * @return $this + * + * @throws Configuration\ConfigurationException */ public function setConfiguration($config = []) { @@ -241,10 +241,10 @@ class Connection * @param string|null $username * @param string|null $password * + * @return Connection + * * @throws Auth\BindException * @throws LdapRecordException - * - * @return Connection */ public function connect($username = null, $password = null) { @@ -274,10 +274,10 @@ class Connection /** * Reconnect to the LDAP server. * + * @return void + * * @throws Auth\BindException * @throws ConnectionException - * - * @return void */ public function reconnect() { @@ -385,9 +385,9 @@ class Connection * * @param Closure $operation * - * @throws LdapRecordException - * * @return mixed + * + * @throws LdapRecordException */ protected function runOperationCallback(Closure $operation) { @@ -442,9 +442,9 @@ class Connection * @param LdapRecordException $e * @param Closure $operation * - * @throws LdapRecordException - * * @return mixed + * + * @throws LdapRecordException */ protected function tryAgainIfCausedByLostConnection(LdapRecordException $e, Closure $operation) { @@ -463,9 +463,9 @@ class Connection * * @param Closure $operation * - * @throws LdapRecordException - * * @return mixed + * + * @throws LdapRecordException */ protected function retry(Closure $operation) { @@ -486,9 +486,9 @@ class Connection * @param LdapRecordException $e * @param Closure $operation * - * @throws LdapRecordException - * * @return mixed + * + * @throws LdapRecordException */ protected function retryOnNextHost(LdapRecordException $e, Closure $operation) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php index 0eacbc3f..01b072b4 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php @@ -149,9 +149,9 @@ class ConnectionManager * * @param string|null $name * - * @throws ContainerException If the given connection does not exist. - * * @return Connection + * + * @throws ContainerException If the given connection does not exist. */ public function get($name = null) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php index f3840c28..b2082e59 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php @@ -39,11 +39,14 @@ class Logger { switch (true) { case $event instanceof AuthEvent: - return $this->auth($event); + $this->auth($event); + break; case $event instanceof ModelEvent: - return $this->model($event); + $this->model($event); + break; case $event instanceof QueryEvent: - return $this->query($event); + $this->query($event); + break; } } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php new file mode 100644 index 00000000..73b1f5a8 --- /dev/null +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php @@ -0,0 +1,113 @@ +dispatcher = $dispatcher; + } + + /** + * Register an event listener with the dispatcher. + * + * @param string|array $events + * @param mixed $listener + * + * @return void + */ + public function listen($events, $listener) + { + $this->dispatcher->listen($events, $listener); + } + + /** + * Determine if a given event has listeners. + * + * @param string $eventName + * + * @return bool + */ + public function hasListeners($eventName) + { + return $this->dispatcher->hasListeners($eventName); + } + + /** + * Fire an event until the first non-null response is returned. + * + * @param string|object $event + * @param mixed $payload + * + * @return null + */ + public function until($event, $payload = []) + { + return null; + } + + /** + * Fire an event and call the listeners. + * + * @param string|object $event + * @param mixed $payload + * @param bool $halt + * + * @return null + */ + public function fire($event, $payload = [], $halt = false) + { + return null; + } + + /** + * Fire an event and call the listeners. + * + * @param string|object $event + * @param mixed $payload + * @param bool $halt + * + * @return null + */ + public function dispatch($event, $payload = [], $halt = false) + { + return null; + } + + /** + * Get all of the listeners for a given event name. + * + * @param string $eventName + * + * @return array + */ + public function getListeners($eventName) + { + return $this->dispatcher->getListeners($eventName); + } + + /** + * Remove a set of listeners from the dispatcher. + * + * @param string $event + * + * @return void + */ + public function forget($event) + { + $this->dispatcher->forget($event); + } +} diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php index 41334b68..9af7ad75 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php @@ -150,19 +150,21 @@ trait HandlesConnection * * @param Closure $operation * - * @throws LdapRecordException - * * @return mixed + * + * @throws LdapRecordException */ protected function executeFailableOperation(Closure $operation) { // If some older versions of PHP, errors are reported instead of throwing - // exceptions, which could be a signifcant detriment to our application. + // exceptions, which could be a significant detriment to our application. // Here, we will enforce these operations to throw exceptions instead. - set_error_handler(function ($severity, $message, $file, $line) { + set_error_handler(function (int $severity, string $message, string $file, int $line): bool { if (! $this->shouldBypassError($message)) { throw new ErrorException($message, $severity, $severity, $file, $line); } + + return true; }); try { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php index 6503cead..0c3574f1 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php @@ -2,6 +2,9 @@ namespace LdapRecord; +use LDAP\Connection as RawLdapConnection; + +/** @psalm-suppress UndefinedClass */ class Ldap implements LdapInterface { use HandlesConnection, DetectsErrors; @@ -104,7 +107,7 @@ class Ldap implements LdapInterface public function getLastError() { if (! $this->connection) { - return; + return null; } return ldap_error($this->connection); @@ -116,7 +119,7 @@ class Ldap implements LdapInterface public function getDetailedError() { if (! $number = $this->errNo()) { - return; + return null; } $this->getOption(LDAP_OPT_DIAGNOSTIC_MESSAGE, $message); @@ -202,7 +205,9 @@ class Ldap implements LdapInterface */ public function close() { - $result = is_resource($this->connection) ? @ldap_close($this->connection) : false; + $result = (is_resource($this->connection) || $this->connection instanceof RawLdapConnection) + ? @ldap_close($this->connection) + : false; $this->connection = null; $this->bound = false; @@ -214,7 +219,7 @@ class Ldap implements LdapInterface /** * @inheritdoc */ - public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []) + public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []) { return $this->executeFailableOperation(function () use ( $dn, @@ -235,7 +240,7 @@ class Ldap implements LdapInterface /** * @inheritdoc */ - public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []) + public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []) { return $this->executeFailableOperation(function () use ( $dn, @@ -256,7 +261,7 @@ class Ldap implements LdapInterface /** * @inheritdoc */ - public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []) + public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []) { return $this->executeFailableOperation(function () use ( $dn, diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php index a1773add..c74fe4e8 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php @@ -156,7 +156,7 @@ interface LdapInterface /** * Return detailed information about an error. * - * Returns false when there was a successful last request. + * Returns null when there was a successful last request. * * Returns DetailedError when there was an error. * @@ -202,9 +202,9 @@ interface LdapInterface * * @see http://php.net/manual/en/function.ldap-start-tls.php * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function startTLS(); @@ -247,7 +247,7 @@ interface LdapInterface * * @return resource */ - public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []); + public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []); /** * Performs a single level search on the current connection. @@ -265,7 +265,7 @@ interface LdapInterface * * @return resource */ - public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []); + public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []); /** * Reads an entry on the current connection. @@ -283,7 +283,7 @@ interface LdapInterface * * @return resource */ - public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []); + public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []); /** * Extract information from an LDAP result. @@ -292,10 +292,10 @@ interface LdapInterface * * @param resource $result * @param int $errorCode - * @param string $dn - * @param string $errorMessage - * @param array $referrals - * @param array $serverControls + * @param ?string $dn + * @param ?string $errorMessage + * @param ?array $referrals + * @param ?array $serverControls * * @return bool */ @@ -310,9 +310,9 @@ interface LdapInterface * @param string $username * @param string $password * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function bind($username, $password); @@ -324,9 +324,9 @@ interface LdapInterface * @param string $dn * @param array $entry * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function add($dn, array $entry); @@ -337,9 +337,9 @@ interface LdapInterface * * @param string $dn * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function delete($dn); @@ -353,9 +353,9 @@ interface LdapInterface * @param string $newParent * @param bool $deleteOldRdn * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function rename($dn, $newRdn, $newParent, $deleteOldRdn = false); @@ -367,9 +367,9 @@ interface LdapInterface * @param string $dn * @param array $entry * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function modify($dn, array $entry); @@ -381,9 +381,9 @@ interface LdapInterface * @param string $dn * @param array $values * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function modifyBatch($dn, array $values); @@ -395,9 +395,9 @@ interface LdapInterface * @param string $dn * @param array $entry * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function modAdd($dn, array $entry); @@ -409,9 +409,9 @@ interface LdapInterface * @param string $dn * @param array $entry * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function modReplace($dn, array $entry); @@ -423,9 +423,9 @@ interface LdapInterface * @param string $dn * @param array $entry * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function modDelete($dn, array $entry); diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php index 79a9d63d..652ad563 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php @@ -78,7 +78,7 @@ class Entry extends BaseEntry implements ActiveDirectory */ public function isDeleted() { - return strtoupper($this->getFirstAttribute('isDeleted')) === 'TRUE'; + return strtoupper((string) $this->getFirstAttribute('isDeleted')) === 'TRUE'; } /** @@ -86,9 +86,9 @@ class Entry extends BaseEntry implements ActiveDirectory * * @param string|null $newParentDn * - * @throws \LdapRecord\LdapRecordException - * * @return bool + * + * @throws \LdapRecord\LdapRecordException */ public function restore($newParentDn = null) { @@ -109,10 +109,9 @@ class Entry extends BaseEntry implements ActiveDirectory } }); - $this->save([ - 'isDeleted' => null, - 'distinguishedName' => $newDn, - ]); + $this->setRawAttribute('distinguishedname', $newDn); + + $this->save(['isDeleted' => null]); } /** @@ -120,9 +119,9 @@ class Entry extends BaseEntry implements ActiveDirectory * * @param string|null $connection * - * @throws \LdapRecord\Models\ModelNotFoundException - * * @return static + * + * @throws \LdapRecord\Models\ModelNotFoundException */ public static function getRootDse($connection = null) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php index 6076f2fd..78458877 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php @@ -63,7 +63,7 @@ class Group extends Entry */ public function getRidAttribute() { - $objectSidComponents = explode('-', $this->getConvertedSid()); + $objectSidComponents = explode('-', (string) $this->getConvertedSid()); return [end($objectSidComponents)]; } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php index 2b1a177b..9f2fbe4d 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php @@ -15,9 +15,9 @@ class InConfigurationContext implements Scope * @param Builder $query * @param Model $model * - * @throws \LdapRecord\Models\ModelNotFoundException - * * @return void + * + * @throws \LdapRecord\Models\ModelNotFoundException */ public function apply(Builder $query, Model $model) { @@ -29,9 +29,9 @@ class InConfigurationContext implements Scope * * @param Model $model * - * @throws \LdapRecord\Models\ModelNotFoundException - * * @return mixed + * + * @throws \LdapRecord\Models\ModelNotFoundException */ protected function getConfigurationNamingContext(Model $model) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php index 84dd74b7..b735b03b 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php @@ -2,6 +2,7 @@ namespace LdapRecord\Models\ActiveDirectory; +use Carbon\Carbon; use Illuminate\Contracts\Auth\Authenticatable; use LdapRecord\Models\ActiveDirectory\Concerns\HasPrimaryGroup; use LdapRecord\Models\ActiveDirectory\Scopes\RejectComputerObjectClass; @@ -117,4 +118,42 @@ class User extends Entry implements Authenticatable { return $query->whereHas('msExchMailboxGuid'); } + + /** + * Scopes the query to users having a lockout value set. + * + * @param Builder $query + * + * @return Builder + */ + public function scopeWhereHasLockout(Builder $query) + { + return $query->where('lockoutTime', '>=', 1); + } + + /** + * Determine if the user is locked out using the domains LockoutDuration group policy value. + * + * @see https://ldapwiki.com/wiki/Active%20Directory%20Account%20Lockout + * @see https://docs.microsoft.com/en-us/windows/security/threat-protection/security-policy-settings/account-lockout-duration + * + * @param string|int $localTimezone + * @param int|null $durationInMinutes + * + * @return bool + */ + public function isLockedOut($localTimezone, $durationInMinutes = null) + { + $time = $this->getFirstAttribute('lockouttime'); + + if (! $time instanceof Carbon) { + return false; + } + + is_int($localTimezone) + ? $time->addMinutes($localTimezone) + : $time->setTimezone($localTimezone)->addMinutes($durationInMinutes ?: 0); + + return ! $time->isPast(); + } } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php index 9c6240bc..7e241462 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php @@ -53,14 +53,14 @@ class AccountControl /** * The account control flag values. * - * @var array + * @var array */ protected $values = []; /** * Constructor. * - * @param int $flag + * @param ?int $flag */ public function __construct($flag = null) { @@ -431,7 +431,7 @@ class AccountControl /** * Get the account control flag values. * - * @return array + * @return array */ public function getValues() { @@ -441,7 +441,7 @@ class AccountControl /** * Set the account control values. * - * @param array $flags + * @param array $flags * * @return void */ diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php index c092173e..c6977a8e 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php @@ -12,7 +12,7 @@ class DistinguishedName /** * The underlying raw value. * - * @var string|null + * @var string */ protected $value; @@ -23,7 +23,7 @@ class DistinguishedName */ public function __construct($value = null) { - $this->value = trim($value); + $this->value = trim((string) $value); } /** @@ -72,6 +72,18 @@ class DistinguishedName return new static($value); } + /** + * Determine if the given value is a valid distinguished name. + * + * @param string $value + * + * @return bool + */ + public static function isValid($value) + { + return ! static::make($value)->isEmpty(); + } + /** * Explode a distinguished name into relative distinguished names. * @@ -81,19 +93,19 @@ class DistinguishedName */ public static function explode($dn) { - $dn = ldap_explode_dn($dn, $withoutAttributes = false); + $components = ldap_explode_dn($dn, (int) $withoutAttributes = false); - if (! is_array($dn)) { + if (! is_array($components)) { return []; } - if (! array_key_exists('count', $dn)) { + if (! array_key_exists('count', $components)) { return []; } - unset($dn['count']); + unset($components['count']); - return $dn; + return $components; } /** @@ -310,6 +322,18 @@ class DistinguishedName return implode(',', $components) ?: null; } + /** + * Determine if the distinguished name is empty. + * + * @return bool + */ + public function isEmpty() + { + return empty( + array_filter($this->values()) + ); + } + /** * Determine if the current distinguished name is a parent of the given child. * diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php index 83dfe716..601902bf 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php @@ -236,7 +236,7 @@ class DistinguishedNameBuilder /** * Build the distinguished name from the components. * - * @return $this + * @return string */ protected function build() { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php index cc04a67d..2f611129 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php @@ -34,7 +34,7 @@ class EscapedValue */ public function __construct($value, $ignore = '', $flags = 0) { - $this->value = $value; + $this->value = (string) $value; $this->ignore = $ignore; $this->flags = $flags; } @@ -59,6 +59,16 @@ class EscapedValue return ldap_escape($this->value, $this->ignore, $this->flags); } + /** + * Get the raw (unescaped) value. + * + * @return mixed + */ + public function raw() + { + return $this->value; + } + /** * Set the characters to exclude from being escaped. * diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php index 7f0b4128..644f0a8d 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php @@ -244,9 +244,9 @@ class Password * * @param int $type * - * @throws InvalidArgumentException - * * @return array + * + * @throws InvalidArgumentException */ protected static function makeCryptPrefixAndLength($type) { @@ -297,9 +297,9 @@ class Password /** * Attempt to retrieve a salt from the encrypted password. * - * @throws LdapRecordException - * * @return string + * + * @throws LdapRecordException */ public static function getSalt($encryptedPassword) { @@ -321,9 +321,9 @@ class Password * * @param string $method * - * @throws \ReflectionException - * * @return bool + * + * @throws \ReflectionException */ public static function hashMethodRequiresSalt($method): bool { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php index abd656c8..e5d9dc34 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php @@ -61,9 +61,9 @@ class Timestamp * * @param mixed $value * - * @throws LdapRecordException - * * @return float|string + * + * @throws LdapRecordException */ public function fromDateTime($value) { @@ -121,9 +121,9 @@ class Timestamp * * @param mixed $value * - * @throws LdapRecordException - * * @return Carbon|false + * + * @throws LdapRecordException */ public function toDateTime($value) { @@ -155,7 +155,7 @@ class Timestamp * * @param string $value * - * @return DateTime|bool + * @return DateTime|false */ protected function convertLdapTimeToDateTime($value) { @@ -184,7 +184,7 @@ class Timestamp * * @param string $value * - * @return DateTime|bool + * @return DateTime|false */ protected function convertWindowsTimeToDateTime($value) { @@ -213,9 +213,9 @@ class Timestamp * * @param int $value * - * @throws \Exception + * @return DateTime|false * - * @return DateTime|bool + * @throws \Exception */ protected function convertWindowsIntegerTimeToDateTime($value) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php index f287454e..451738ab 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php @@ -31,6 +31,7 @@ trait CanAuthenticate */ public function getAuthPassword() { + return ''; } /** @@ -40,6 +41,7 @@ trait CanAuthenticate */ public function getRememberToken() { + return ''; } /** @@ -60,5 +62,6 @@ trait CanAuthenticate */ public function getRememberTokenName() { + return ''; } } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php index 20fcec02..b5f33357 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php @@ -238,26 +238,28 @@ trait HasAttributes * Returns the models attribute by its key. * * @param int|string $key + * @param mixed $default * * @return mixed */ - public function getAttribute($key) + public function getAttribute($key, $default = null) { if (! $key) { return; } - return $this->getAttributeValue($key); + return $this->getAttributeValue($key, $default); } /** * Get an attributes value. * * @param string $key + * @param mixed $default * * @return mixed */ - public function getAttributeValue($key) + public function getAttributeValue($key, $default = null) { $key = $this->normalizeAttributeKey($key); $value = $this->getAttributeFromArray($key); @@ -274,7 +276,7 @@ trait HasAttributes return $this->castAttribute($key, $value); } - return $value; + return is_null($value) ? $default : $value; } /** @@ -311,9 +313,9 @@ trait HasAttributes * @param string $type * @param mixed $value * - * @throws LdapRecordException - * * @return float|string + * + * @throws LdapRecordException */ public function fromDateTime($type, $value) { @@ -326,9 +328,9 @@ trait HasAttributes * @param mixed $value * @param string $type * - * @throws LdapRecordException - * * @return Carbon|false + * + * @throws LdapRecordException */ public function asDateTime($value, $type) { @@ -686,13 +688,14 @@ trait HasAttributes * Returns the first attribute by the specified key. * * @param string $key + * @param mixed $default * * @return mixed */ - public function getFirstAttribute($key) + public function getFirstAttribute($key, $default = null) { return Arr::first( - Arr::wrap($this->getAttribute($key)) + Arr::wrap($this->getAttribute($key, $default)), ); } @@ -707,10 +710,10 @@ trait HasAttributes } /** - * Set an attribute value by the specified key and sub-key. + * Set an attribute value by the specified key. * - * @param mixed $key - * @param mixed $value + * @param string $key + * @param mixed $value * * @return $this */ @@ -737,6 +740,23 @@ trait HasAttributes return $this; } + /** + * Set an attribute on the model. No checking is done. + * + * @param string $key + * @param mixed $value + * + * @return $this + */ + public function setRawAttribute($key, $value) + { + $key = $this->normalizeAttributeKey($key); + + $this->attributes[$key] = Arr::wrap($value); + + return $this; + } + /** * Set the models first attribute value. * diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php index 1bc76d09..5adec96e 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php @@ -3,10 +3,39 @@ namespace LdapRecord\Models\Concerns; use Closure; +use LdapRecord\Events\NullDispatcher; use LdapRecord\Models\Events\Event; trait HasEvents { + /** + * Execute the callback without raising any events. + * + * @param Closure $callback + * + * @return mixed + */ + protected static function withoutEvents(Closure $callback) + { + $container = static::getConnectionContainer(); + + $dispatcher = $container->getEventDispatcher(); + + if ($dispatcher) { + $container->setEventDispatcher( + new NullDispatcher($dispatcher) + ); + } + + try { + return $callback(); + } finally { + if ($dispatcher) { + $container->setEventDispatcher($dispatcher); + } + } + } + /** * Fires the specified model event. * diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php index c14abad2..f7552c1b 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php @@ -14,9 +14,9 @@ trait HasGlobalScopes * @param Scope|Closure|string $scope * @param Closure|null $implementation * - * @throws InvalidArgumentException - * * @return mixed + * + * @throws InvalidArgumentException */ public static function addGlobalScope($scope, Closure $implementation = null) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php index 98224566..1a938c14 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php @@ -159,9 +159,9 @@ trait HasPassword * @param string $password * @param string $salt * - * @throws LdapRecordException - * * @return string + * + * @throws LdapRecordException */ protected function getHashedPassword($method, $password, $salt = null) { @@ -179,9 +179,9 @@ trait HasPassword /** * Validates that the current LDAP connection is secure. * - * @throws ConnectionException - * * @return void + * + * @throws ConnectionException */ protected function validateSecureConnection() { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php index 6ba24b45..2e11696b 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php @@ -3,6 +3,7 @@ namespace LdapRecord\Models; use ArrayAccess; +use Illuminate\Contracts\Support\Arrayable; use InvalidArgumentException; use JsonSerializable; use LdapRecord\Connection; @@ -17,7 +18,7 @@ use LdapRecord\Support\Arr; use UnexpectedValueException; /** @mixin Builder */ -abstract class Model implements ArrayAccess, JsonSerializable +abstract class Model implements ArrayAccess, Arrayable, JsonSerializable { use EscapesValues; use Concerns\HasEvents; @@ -28,7 +29,7 @@ abstract class Model implements ArrayAccess, JsonSerializable use Concerns\HasRelationships; /** - * Indicates if the model exists in the LDAP directory. + * Indicates if the model exists in the directory. * * @var bool */ @@ -63,7 +64,7 @@ abstract class Model implements ArrayAccess, JsonSerializable protected $in; /** - * The object classes of the LDAP model. + * The object classes of the model. * * @var array */ @@ -77,7 +78,7 @@ abstract class Model implements ArrayAccess, JsonSerializable protected static $container; /** - * The LDAP connection name for the model. + * The connection name for the model. * * @var string|null */ @@ -138,7 +139,7 @@ abstract class Model implements ArrayAccess, JsonSerializable } /** - * The "booting" method of the model. + * The "boot" method of the model. * * @return void */ @@ -204,7 +205,7 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @param string $dn * - * @return static + * @return $this */ public function setDn($dn) { @@ -214,7 +215,31 @@ abstract class Model implements ArrayAccess, JsonSerializable } /** - * Get the LDAP connection for the model. + * A mutator for setting the models distinguished name. + * + * @param string $dn + * + * @return $this + */ + public function setDnAttribute($dn) + { + return $this->setRawAttribute('dn', $dn)->setDn($dn); + } + + /** + * A mutator for setting the models distinguished name. + * + * @param string $dn + * + * @return $this + */ + public function setDistinguishedNameAttribute($dn) + { + return $this->setRawAttribute('distinguishedname', $dn)->setDn($dn); + } + + /** + * Get the connection for the model. * * @return Connection */ @@ -275,6 +300,18 @@ abstract class Model implements ArrayAccess, JsonSerializable return static::query()->select($attributes)->paginate(); } + /** + * Make a new model instance. + * + * @param array $attributes + * + * @return static + */ + public static function make($attributes = []) + { + return new static($attributes); + } + /** * Begin querying the model. * @@ -501,6 +538,7 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @return bool */ + #[\ReturnTypeWillChange] public function offsetExists($offset) { return ! is_null($this->getAttribute($offset)); @@ -513,6 +551,7 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @return mixed */ + #[\ReturnTypeWillChange] public function offsetGet($offset) { return $this->getAttribute($offset); @@ -526,6 +565,7 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @return void */ + #[\ReturnTypeWillChange] public function offsetSet($offset, $value) { $this->setAttribute($offset, $value); @@ -538,6 +578,7 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @return void */ + #[\ReturnTypeWillChange] public function offsetUnset($offset) { unset($this->attributes[$offset]); @@ -568,15 +609,26 @@ abstract class Model implements ArrayAccess, JsonSerializable } /** - * Convert the object into something JSON serializable. + * Convert the model to its JSON encodeable array form. * * @return array */ - public function jsonSerialize() + public function toArray() { return $this->attributesToArray(); } + /** + * Convert the model's attributes into JSON encodeable values. + * + * @return array + */ + #[\ReturnTypeWillChange] + public function jsonSerialize() + { + return $this->toArray(); + } + /** * Converts extra attributes for JSON serialization. * @@ -615,17 +667,31 @@ abstract class Model implements ArrayAccess, JsonSerializable /** * Determine if two models have the same distinguished name and belong to the same connection. * - * @param static $model + * @param Model|null $model * * @return bool */ - public function is(self $model) + public function is($model) { - return $this->dn == $model->getDn() && $this->getConnectionName() == $model->getConnectionName(); + return ! is_null($model) + && $this->dn == $model->getDn() + && $this->getConnectionName() == $model->getConnectionName(); } /** - * Hydrate a new collection of models from LDAP search results. + * Determine if two models are not the same. + * + * @param Model|null $model + * + * @return bool + */ + public function isNot($model) + { + return ! $this->is($model); + } + + /** + * Hydrate a new collection of models from search results. * * @param array $records * @@ -714,9 +780,9 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @param array|BatchModification $mod * - * @throws InvalidArgumentException - * * @return $this + * + * @throws InvalidArgumentException */ public function addModification($mod = []) { @@ -818,7 +884,7 @@ abstract class Model implements ArrayAccess, JsonSerializable /** * Get the model's object GUID key. * - * @return void + * @return string */ public function getObjectGuidKey() { @@ -942,14 +1008,30 @@ abstract class Model implements ArrayAccess, JsonSerializable return $this; } + /** + * Save the model to the directory without raising any events. + * + * @param array $attributes + * + * @return void + * + * @throws \LdapRecord\LdapRecordException + */ + public function saveQuietly(array $attributes = []) + { + static::withoutEvents(function () use ($attributes) { + $this->save($attributes); + }); + } + /** * Save the model to the directory. * * @param array $attributes The attributes to update or create for the current entry. * - * @throws \LdapRecord\LdapRecordException - * * @return void + * + * @throws \LdapRecord\LdapRecordException */ public function save(array $attributes = []) { @@ -967,9 +1049,9 @@ abstract class Model implements ArrayAccess, JsonSerializable /** * Inserts the model into the directory. * - * @throws \LdapRecord\LdapRecordException - * * @return void + * + * @throws \LdapRecord\LdapRecordException */ protected function performInsert() { @@ -1009,9 +1091,9 @@ abstract class Model implements ArrayAccess, JsonSerializable /** * Updates the model in the directory. * - * @throws \LdapRecord\LdapRecordException - * * @return void + * + * @throws \LdapRecord\LdapRecordException */ protected function performUpdate() { @@ -1035,9 +1117,9 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @param array $attributes The attributes for the new entry. * - * @throws \LdapRecord\LdapRecordException - * * @return Model + * + * @throws \LdapRecord\LdapRecordException */ public static function create(array $attributes = []) { @@ -1054,14 +1136,14 @@ abstract class Model implements ArrayAccess, JsonSerializable * @param string $attribute The attribute to create * @param mixed $value The value of the new attribute * + * @return void + * * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function createAttribute($attribute, $value) { - $this->validateExistence(); + $this->requireExistence(); $this->newQuery()->insertAttributes($this->dn, [$attribute => (array) $value]); @@ -1073,14 +1155,14 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @param array $attributes The attributes to update for the current entry. * + * @return void + * * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function update(array $attributes = []) { - $this->validateExistence(); + $this->requireExistence(); $this->save($attributes); } @@ -1091,14 +1173,14 @@ abstract class Model implements ArrayAccess, JsonSerializable * @param string $attribute The attribute to modify * @param mixed $value The new value for the attribute * + * @return void + * * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function updateAttribute($attribute, $value) { - $this->validateExistence(); + $this->requireExistence(); $this->newQuery()->updateAttributes($this->dn, [$attribute => (array) $value]); @@ -1111,9 +1193,9 @@ abstract class Model implements ArrayAccess, JsonSerializable * @param Collection|array|string $dns * @param bool $recursive * - * @throws \LdapRecord\LdapRecordException - * * @return int + * + * @throws \LdapRecord\LdapRecordException */ public static function destroy($dns, $recursive = false) { @@ -1144,14 +1226,14 @@ abstract class Model implements ArrayAccess, JsonSerializable * * @param bool $recursive Whether to recursively delete leaf nodes (models that are children). * + * @return void + * * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function delete($recursive = false) { - $this->validateExistence(); + $this->requireExistence(); $this->fireModelEvent(new Events\Deleting($this)); @@ -1172,18 +1254,17 @@ abstract class Model implements ArrayAccess, JsonSerializable /** * Deletes leaf nodes that are attached to the model. * - * @throws \LdapRecord\LdapRecordException + * @return void * - * @return Collection + * @throws \LdapRecord\LdapRecordException */ protected function deleteLeafNodes() { - return $this->newQueryWithoutScopes() + $this->newQueryWithoutScopes() ->in($this->dn) ->listing() - ->paginate() - ->each(function (self $model) { - $model->delete($recursive = true); + ->chunk(250, function ($models) { + $models->each->delete($recursive = true); }); } @@ -1200,14 +1281,14 @@ abstract class Model implements ArrayAccess, JsonSerializable * * ["memberuid" => []] * + * @return void + * * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function deleteAttribute($attributes) { - $this->validateExistence(); + $this->requireExistence(); $attributes = $this->makeDeletableAttributes($attributes); @@ -1261,15 +1342,15 @@ abstract class Model implements ArrayAccess, JsonSerializable * @param static|string $newParentDn The new parent of the current model. * @param bool $deleteOldRdn Whether to delete the old models relative distinguished name once renamed / moved. * + * @return void + * * @throws UnexpectedValueException * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function move($newParentDn, $deleteOldRdn = true) { - $this->validateExistence(); + $this->requireExistence(); if (! $rdn = $this->getRdn()) { throw new UnexpectedValueException('Current model does not contain an RDN to move.'); @@ -1285,14 +1366,14 @@ abstract class Model implements ArrayAccess, JsonSerializable * @param static|string|null $newParentDn The models new parent distinguished name (if moving). Leave this null if you are only renaming. Example: "ou=MovedUsers,dc=acme,dc=org" * @param bool|true $deleteOldRdn Whether to delete the old models relative distinguished name once renamed / moved. * + * @return void + * * @throws ModelDoesNotExistException * @throws \LdapRecord\LdapRecordException - * - * @return void */ public function rename($rdn, $newParentDn = null, $deleteOldRdn = true) { - $this->validateExistence(); + $this->requireExistence(); if ($newParentDn instanceof self) { $newParentDn = $newParentDn->getDn(); @@ -1312,6 +1393,13 @@ abstract class Model implements ArrayAccess, JsonSerializable return; } + // If the RDN we have been given is empty when parsed, we must + // have been given a string, with no attribute. In this case, + // we will create a new RDN using the current DN's head. + if ($this->newDn($rdn)->isEmpty()) { + $rdn = $this->getUpdateableRdn($rdn); + } + $this->fireModelEvent(new Renaming($this, $rdn, $newParentDn)); $this->newQuery()->rename($this->dn, $rdn, $newParentDn, $deleteOldRdn); @@ -1337,6 +1425,18 @@ abstract class Model implements ArrayAccess, JsonSerializable $this->wasRecentlyRenamed = true; } + /** + * Get an updateable RDN for the model. + * + * @param string $name + * + * @return string + */ + public function getUpdateableRdn($name) + { + return $this->getCreatableRdn($name, $this->newDn($this->dn)->head()); + } + /** * Get a distinguished name that is creatable for the model. * @@ -1426,13 +1526,13 @@ abstract class Model implements ArrayAccess, JsonSerializable } /** - * Validates that the current model exists. - * - * @throws ModelDoesNotExistException + * Throw an exception if the model does not exist. * * @return void + * + * @throws ModelDoesNotExistException */ - protected function validateExistence() + protected function requireExistence() { if (! $this->exists || is_null($this->dn)) { throw ModelDoesNotExistException::forModel($this); diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php index d8dfa08c..ae36720c 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php @@ -284,9 +284,9 @@ class HasMany extends OneToMany * * @param string $model * - * @throws ModelNotFoundException - * * @return Model + * + * @throws ModelNotFoundException */ protected function getForeignModelByValueOrFail($model) { @@ -309,9 +309,9 @@ class HasMany extends OneToMany * @param string|array $bypass * @param mixed $value * - * @throws LdapRecordException - * * @return mixed + * + * @throws LdapRecordException */ protected function attemptFailableOperation($operation, $bypass, $value) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php index 9a9b2f9b..7bad4ab6 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php @@ -27,9 +27,9 @@ class HasOne extends Relation * * @param Model|string $model * - * @throws \LdapRecord\LdapRecordException - * * @return Model|string + * + * @throws \LdapRecord\LdapRecordException */ public function attach($model) { @@ -45,9 +45,9 @@ class HasOne extends Relation /** * Detach the related model from the parent. * - * @throws \LdapRecord\LdapRecordException - * * @return void + * + * @throws \LdapRecord\LdapRecordException */ public function detach() { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php index d0a407cc..6d14c857 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php @@ -49,7 +49,7 @@ abstract class OneToMany extends Relation /** * Set the relation to load with its parent. * - * @param OneToMany $relation + * @param Relation $relation * * @return $this */ diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php index c75afa2e..b9e31960 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php @@ -6,6 +6,7 @@ use BadMethodCallException; use Closure; use DateTimeInterface; use InvalidArgumentException; +use LDAP\Result; use LdapRecord\Connection; use LdapRecord\Container; use LdapRecord\EscapesValues; @@ -19,6 +20,7 @@ use LdapRecord\Query\Pagination\Paginator; use LdapRecord\Support\Arr; use LdapRecord\Utilities; +/** @psalm-suppress UndefinedClass */ class Builder { use EscapesValues; @@ -48,6 +50,13 @@ class Builder */ public $controls = []; + /** + * The LDAP server controls that were processed. + * + * @var array + */ + public $controlsResponse = []; + /** * The size limit of the query. * @@ -238,12 +247,12 @@ class Builder * * After running the callback, the columns are reset to the original value. * - * @param array $columns - * @param callable $callback + * @param array $columns + * @param Closure $callback * * @return mixed */ - protected function onceWithColumns($columns, $callback) + protected function onceWithColumns($columns, Closure $callback) { $original = $this->columns; @@ -383,8 +392,8 @@ class Builder { return str_replace( '{base}', - $this->baseDn, - $dn instanceof Model ? $dn->getDn() : $dn + $this->baseDn ?: '', + (string) ($dn instanceof Model ? $dn->getDn() : $dn) ); } @@ -500,6 +509,25 @@ class Builder }); } + /** + * Execute a callback over each item while chunking. + * + * @param Closure $callback + * @param int $count + * + * @return bool + */ + public function each(Closure $callback, $count = 1000) + { + return $this->chunk($count, function ($results) use ($callback) { + foreach ($results as $key => $value) { + if ($callback($value, $key) === false) { + return false; + } + } + }); + } + /** * Chunk the results of a paginated LDAP query. * @@ -507,7 +535,7 @@ class Builder * @param Closure $callback * @param bool $isCritical * - * @return void + * @return bool */ public function chunk($pageSize, Closure $callback, $isCritical = false) { @@ -515,11 +543,19 @@ class Builder $query = $this->getQuery(); + $page = 1; + foreach ($this->runChunk($query, $pageSize, $isCritical) as $chunk) { - $callback($this->process($chunk)); + if ($callback($this->process($chunk), $page) === false) { + return false; + } + + $page++; } $this->logQuery($this, 'chunk', $this->getElapsedTime($start)); + + return true; } /** @@ -549,7 +585,11 @@ class Builder { unset($results['count']); - return $this->paginated ? $this->flattenPages($results) : $results; + if ($this->paginated) { + return $this->flattenPages($results); + } + + return $results; } /** @@ -582,9 +622,7 @@ class Builder */ protected function getCachedResponse($query, Closure $callback) { - // If caching is enabled and we have a cache instance available, - // we will try to retrieve the cached results instead. - if ($this->caching && $this->cache) { + if ($this->cache && $this->caching) { $key = $this->getCacheKey($query); if ($this->flushCache) { @@ -594,7 +632,6 @@ class Builder return $this->cache->remember($key, $this->cacheUntil, $callback); } - // Otherwise, we will simply execute the callback. return $callback(); } @@ -642,10 +679,25 @@ class Builder } return $this->connection->run(function (LdapInterface $ldap) use ($resource) { + $this->controlsResponse = $this->controls; + + $errorCode = 0; + $dn = $errorMessage = $refs = null; + + // Process the server controls response. + $ldap->parseResult( + $resource, + $errorCode, + $dn, + $errorMessage, + $refs, + $this->controlsResponse + ); + $entries = $ldap->getEntries($resource); // Free up memory. - if (is_resource($resource)) { + if (is_resource($resource) || $resource instanceof Result) { $ldap->freeResult($resource); } @@ -684,7 +736,9 @@ class Builder */ public function first($columns = ['*']) { - return Arr::get($this->limit(1)->get($columns), 0); + return Arr::first( + $this->limit(1)->get($columns) + ); } /** @@ -694,9 +748,9 @@ class Builder * * @param array|string $columns * - * @throws ObjectNotFoundException + * @return Model|array * - * @return Model|static + * @throws ObjectNotFoundException */ public function firstOrFail($columns = ['*']) { @@ -707,6 +761,75 @@ class Builder return $record; } + /** + * Return the first entry in a result, or execute the callback. + * + * @param Closure $callback + * + * @return Model|mixed + */ + public function firstOr(Closure $callback) + { + return $this->first() ?: $callback(); + } + + /** + * Execute the query and get the first result if it's the sole matching record. + * + * @param array|string $columns + * + * @return Model|array + * + * @throws ObjectsNotFoundException + * @throws MultipleObjectsFoundException + */ + public function sole($columns = ['*']) + { + $result = $this->limit(2)->get($columns); + + if (empty($result)) { + throw new ObjectsNotFoundException; + } + + if (count($result) > 1) { + throw new MultipleObjectsFoundException; + } + + return reset($result); + } + + /** + * Determine if any results exist for the current query. + * + * @return bool + */ + public function exists() + { + return ! is_null($this->first()); + } + + /** + * Determine if no results exist for the current query. + * + * @return bool + */ + public function doesntExist() + { + return ! $this->exists(); + } + + /** + * Execute the given callback if no rows exist for the current query. + * + * @param Closure $callback + * + * @return bool|mixed + */ + public function existsOr(Closure $callback) + { + return $this->exists() ? true : $callback(); + } + /** * Throws a not found exception. * @@ -747,9 +870,9 @@ class Builder * @param string $value * @param array|string $columns * - * @throws ObjectNotFoundException - * * @return Model + * + * @throws ObjectNotFoundException */ public function findByOrFail($attribute, $value, $columns = ['*']) { @@ -830,9 +953,9 @@ class Builder * @param string $dn * @param array|string $columns * - * @throws ObjectNotFoundException - * * @return Model|static + * + * @throws ObjectNotFoundException */ public function findOrFail($dn, $columns = ['*']) { @@ -876,6 +999,33 @@ class Builder return $this; } + /** + * Add an order by control to the query. + * + * @param string $attribute + * @param string $direction + * + * @return $this + */ + public function orderBy($attribute, $direction = 'asc') + { + return $this->addControl(LDAP_CONTROL_SORTREQUEST, true, [ + ['attr' => $attribute, 'reverse' => $direction === 'desc'], + ]); + } + + /** + * Add an order by descending control to the query. + * + * @param string $attribute + * + * @return $this + */ + public function orderByDesc($attribute) + { + return $this->orderBy($attribute, 'desc'); + } + /** * Adds a raw filter to the current query. * @@ -951,9 +1101,9 @@ class Builder * @param string $boolean * @param bool $raw * - * @throws InvalidArgumentException - * * @return $this + * + * @throws InvalidArgumentException */ public function where($field, $operator = null, $value = null, $boolean = 'and', $raw = false) { @@ -1414,9 +1564,9 @@ class Builder * @param string $type The type of filter to add. * @param array $bindings The bindings of the filter. * - * @throws InvalidArgumentException - * * @return $this + * + * @throws InvalidArgumentException */ public function addFilter($type, array $bindings) { @@ -1610,9 +1760,9 @@ class Builder * @param string $dn * @param array $attributes * - * @throws LdapRecordException - * * @return bool + * + * @throws LdapRecordException */ public function insert($dn, array $attributes) { @@ -1728,9 +1878,9 @@ class Builder * @param string $method * @param array $parameters * - * @throws BadMethodCallException - * * @return mixed + * + * @throws BadMethodCallException */ public function __call($method, $parameters) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php index a02146dc..036affa2 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php @@ -13,6 +13,7 @@ class Collection extends BaseCollection protected function valueRetriever($value) { if ($this->useAsCallable($value)) { + /** @var callable $value */ return $value; } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php index f13ddeb3..4f17ea2a 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php @@ -9,14 +9,14 @@ class QueryExecuted /** * The LDAP filter that was used for the query. * - * @var string + * @var Builder */ protected $query; /** * The number of milliseconds it took to execute the query. * - * @var float + * @var ?float */ protected $time; diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php index 3217173e..35a6c484 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php @@ -506,9 +506,9 @@ class Grammar * * @param array $where * - * @throws UnexpectedValueException - * * @return string + * + * @throws UnexpectedValueException */ protected function compileWhere(array $where) { @@ -522,9 +522,9 @@ class Grammar * * @param string $operator * - * @throws UnexpectedValueException - * * @return string + * + * @throws UnexpectedValueException */ protected function makeCompileMethod($operator) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php index 8923015e..c3911d80 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php @@ -34,9 +34,9 @@ class ActiveDirectoryBuilder extends Builder * @param string $sid * @param array|string $columns * - * @throws ModelNotFoundException - * * @return \LdapRecord\Models\ActiveDirectory\Entry|static + * + * @throws ModelNotFoundException */ public function findBySidOrFail($sid, $columns = []) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php index eed5e91e..234dd0ad 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php @@ -181,9 +181,9 @@ class Builder extends BaseBuilder * @param string $value * @param array|string $columns * - * @throws ModelNotFoundException - * * @return Model + * + * @throws ModelNotFoundException */ public function findByAnrOrFail($value, $columns = ['*']) { @@ -271,9 +271,9 @@ class Builder extends BaseBuilder * @param string $guid * @param array|string $columns * - * @throws ModelNotFoundException - * * @return Model|static + * + * @throws ModelNotFoundException */ public function findByGuidOrFail($guid, $columns = ['*']) { @@ -434,7 +434,7 @@ class Builder extends BaseBuilder if (! $this->model->isDateAttribute($field)) { throw new \UnexpectedValueException( "Cannot convert field [$field] to an LDAP timestamp. You must add this field as a model date." - .' Refer to https://ldaprecord.com/docs/model-mutators/#date-mutators' + .' Refer to https://ldaprecord.com/docs/core/v2/model-mutators/#date-mutators' ); } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php new file mode 100644 index 00000000..0ece752c --- /dev/null +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php @@ -0,0 +1,9 @@ +updateServerControls($ldap, $resource); $pages[] = $this->query->parse($resource); - } while (! empty($this->fetchCookie())); + } while ($this->shouldContinue()); $this->resetServerControls($ldap); return $pages; } + /** + * Whether the paginater should continue iterating. + * + * @return bool + */ + protected function shouldContinue() + { + $cookie = (string) $this->fetchCookie(); + + return $cookie !== ''; + } + /** * Fetch the pagination cookie. * @@ -106,7 +118,7 @@ abstract class AbstractPaginator * * @param LdapInterface $ldap * - * @return mixed + * @return void */ abstract protected function resetServerControls(LdapInterface $ldap); diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php index 2974b8fd..b9df77e4 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php @@ -11,7 +11,7 @@ class LazyPaginator extends Paginator * * @param LdapInterface $ldap * - * @return Generator + * @return \Generator */ public function execute(LdapInterface $ldap) { @@ -27,7 +27,7 @@ class LazyPaginator extends Paginator $this->updateServerControls($ldap, $resource); yield $this->query->parse($resource); - } while (! empty($this->fetchCookie())); + } while ($this->shouldContinue()); $this->resetServerControls($ldap); } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php index 9ab6e670..c0a31afd 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php @@ -37,7 +37,9 @@ class Paginator extends AbstractPaginator */ protected function updateServerControls(LdapInterface $ldap, $resource) { - $errorCode = $dn = $errorMessage = $refs = null; + $errorCode = 0; + $dn = $errorMessage = $refs = null; + $controls = $this->query->controls; $ldap->parseResult( $resource, @@ -45,20 +47,15 @@ class Paginator extends AbstractPaginator $dn, $errorMessage, $refs, - $this->query->controls + $controls ); - $this->resetPageSize(); - } + $cookie = $controls[LDAP_CONTROL_PAGEDRESULTS]['value']['cookie'] ?? ''; - /** - * Reset the page control page size. - * - * @return void - */ - protected function resetPageSize() - { - $this->query->controls[LDAP_CONTROL_PAGEDRESULTS]['value']['size'] = $this->perPage; + $this->query->controls[LDAP_CONTROL_PAGEDRESULTS]['value'] = [ + 'size' => $this->perPage, + 'cookie' => $cookie, + ]; } /** @@ -66,6 +63,6 @@ class Paginator extends AbstractPaginator */ protected function resetServerControls(LdapInterface $ldap) { - $this->query->controls = []; + unset($this->query->controls[LDAP_CONTROL_PAGEDRESULTS]); } } diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php index 70640af9..9d50dcdf 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php @@ -11,9 +11,9 @@ class DirectoryFake * * @param string|null $name * - * @throws \LdapRecord\ContainerException - * * @return ConnectionFake + * + * @throws \LdapRecord\ContainerException */ public static function setup($name = null) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php index 7ba0e153..00470e14 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php @@ -2,6 +2,7 @@ namespace LdapRecord\Testing; +use Closure; use Exception; use LdapRecord\DetailedError; use LdapRecord\DetectsErrors; @@ -81,11 +82,14 @@ class LdapFake implements LdapInterface $expectations = Arr::wrap($expectations); foreach ($expectations as $key => $expectation) { - // If the key is non-numeric, we will assume - // that the string is the method name and - // the expectation is the return value. - if (! is_numeric($key)) { - $expectation = static::operation($key)->andReturn($expectation); + if (! is_int($key)) { + $operation = static::operation($key); + + $expectation instanceof Closure + ? $expectation($operation) + : $operation->andReturn($expectation); + + $expectation = $operation; } if (! $expectation instanceof LdapExpectation) { @@ -322,7 +326,7 @@ class LdapFake implements LdapInterface /** * @inheritdoc */ - public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []) + public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []) { return $this->resolveExpectation('search', func_get_args()); } @@ -330,7 +334,7 @@ class LdapFake implements LdapInterface /** * @inheritdoc */ - public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []) + public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []) { return $this->resolveExpectation('listing', func_get_args()); } @@ -338,7 +342,7 @@ class LdapFake implements LdapInterface /** * @inheritdoc */ - public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = null, $serverControls = []) + public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []) { return $this->resolveExpectation('read', func_get_args()); } @@ -453,9 +457,9 @@ class LdapFake implements LdapInterface * @param string $method * @param array $args * - * @throws Exception - * * @return mixed + * + * @throws Exception */ protected function resolveExpectation($method, array $args = []) { diff --git a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php index 0f0ca3c7..01d55c79 100644 --- a/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php +++ b/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php @@ -112,7 +112,7 @@ class Utilities */ public static function binaryGuidToString($binGuid) { - if (trim($binGuid) == '' || is_null($binGuid)) { + if (is_null($binGuid) || trim($binGuid) == '') { return; } @@ -179,7 +179,7 @@ class Utilities */ public static function isValidSid($sid) { - return (bool) preg_match("/^S-\d(-\d{1,10}){1,16}$/i", $sid); + return (bool) preg_match("/^S-\d(-\d{1,10}){1,16}$/i", (string) $sid); } /** @@ -191,6 +191,6 @@ class Utilities */ public static function isValidGuid($guid) { - return (bool) preg_match('/^([0-9a-fA-F]){8}(-([0-9a-fA-F]){4}){3}-([0-9a-fA-F]){12}$/', $guid); + return (bool) preg_match('/^([0-9a-fA-F]){8}(-([0-9a-fA-F]){4}){3}-([0-9a-fA-F]){12}$/', (string) $guid); } } diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Auth/Guard.php b/data/web/inc/lib/vendor/illuminate/contracts/Auth/Guard.php index 2a27fb5f..2796f1ae 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Auth/Guard.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Auth/Guard.php @@ -40,6 +40,13 @@ interface Guard */ public function validate(array $credentials = []); + /** + * Determine if the guard has a user instance. + * + * @return bool + */ + public function hasUser(); + /** * Set the current user. * diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Auth/PasswordBrokerFactory.php b/data/web/inc/lib/vendor/illuminate/contracts/Auth/PasswordBrokerFactory.php index 47b1c089..683a9030 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Auth/PasswordBrokerFactory.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Auth/PasswordBrokerFactory.php @@ -8,7 +8,7 @@ interface PasswordBrokerFactory * Get a password broker instance by name. * * @param string|null $name - * @return mixed + * @return \Illuminate\Contracts\Auth\PasswordBroker */ public function broker($name = null); } diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/Broadcaster.php b/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/Broadcaster.php index 1034e440..2d317d0a 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/Broadcaster.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/Broadcaster.php @@ -28,6 +28,8 @@ interface Broadcaster * @param string $event * @param array $payload * @return void + * + * @throws \Illuminate\Broadcasting\BroadcastException */ public function broadcast(array $channels, $event, array $payload = []); } diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBroadcast.php b/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBroadcast.php index a4802fe4..3dc4662c 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBroadcast.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBroadcast.php @@ -7,7 +7,7 @@ interface ShouldBroadcast /** * Get the channels the event should broadcast on. * - * @return \Illuminate\Broadcasting\Channel|\Illuminate\Broadcasting\Channel[] + * @return \Illuminate\Broadcasting\Channel|\Illuminate\Broadcasting\Channel[]|string[]|string */ public function broadcastOn(); } diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php b/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php index 1b8bb640..7d7f2c96 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php @@ -81,6 +81,24 @@ interface Container extends ContainerInterface */ public function singletonIf($abstract, $concrete = null); + /** + * Register a scoped binding in the container. + * + * @param string $abstract + * @param \Closure|string|null $concrete + * @return void + */ + public function scoped($abstract, $concrete = null); + + /** + * Register a scoped binding if it hasn't already been registered. + * + * @param string $abstract + * @param \Closure|string|null $concrete + * @return void + */ + public function scopedIf($abstract, $concrete = null); + /** * "Extend" an abstract type in the container. * @@ -163,6 +181,15 @@ interface Container extends ContainerInterface */ public function resolved($abstract); + /** + * Register a new before resolving callback. + * + * @param \Closure|string $abstract + * @param \Closure|null $callback + * @return void + */ + public function beforeResolving($abstract, Closure $callback = null); + /** * Register a new resolving callback. * diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php b/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php index 05e36253..1fc7fc15 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php @@ -15,7 +15,7 @@ interface ContextualBindingBuilder /** * Define the implementation for the contextual binding. * - * @param \Closure|string $implementation + * @param \Closure|string|array $implementation * @return void */ public function give($implementation); @@ -27,4 +27,13 @@ interface ContextualBindingBuilder * @return void */ public function giveTagged($tag); + + /** + * Specify the configuration item to bind as a primitive. + * + * @param string $key + * @param ?string $default + * @return void + */ + public function giveConfig($key, $default = null); } diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Builder.php b/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Builder.php new file mode 100644 index 00000000..6fdf405c --- /dev/null +++ b/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Builder.php @@ -0,0 +1,14 @@ + */ public function getQueueableIds(); /** * Get the relationships of the entities being queued. * - * @return array + * @return array */ public function getQueueableRelations(); diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php b/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php index 2cd928dc..86c16cab 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php @@ -7,7 +7,7 @@ interface ResponseFactory /** * Create a new response instance. * - * @param string $content + * @param array|string $content * @param int $status * @param array $headers * @return \Illuminate\Http\Response diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Routing/UrlGenerator.php b/data/web/inc/lib/vendor/illuminate/contracts/Routing/UrlGenerator.php index e576dda1..cca221cc 100644 --- a/data/web/inc/lib/vendor/illuminate/contracts/Routing/UrlGenerator.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Routing/UrlGenerator.php @@ -69,6 +69,13 @@ interface UrlGenerator */ public function action($action, $parameters = [], $absolute = true); + /** + * Get the root controller namespace. + * + * @return string + */ + public function getRootControllerNamespace(); + /** * Set the root controller namespace. * diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Support/Arrayable.php b/data/web/inc/lib/vendor/illuminate/contracts/Support/Arrayable.php index 5ad93b70..3194bd11 100755 --- a/data/web/inc/lib/vendor/illuminate/contracts/Support/Arrayable.php +++ b/data/web/inc/lib/vendor/illuminate/contracts/Support/Arrayable.php @@ -2,12 +2,16 @@ namespace Illuminate\Contracts\Support; +/** + * @template TKey of array-key + * @template TValue + */ interface Arrayable { /** * Get the instance as an array. * - * @return array + * @return array */ public function toArray(); } diff --git a/data/web/inc/lib/vendor/illuminate/contracts/Support/CanBeEscapedWhenCastToString.php b/data/web/inc/lib/vendor/illuminate/contracts/Support/CanBeEscapedWhenCastToString.php new file mode 100644 index 00000000..e1be6fef --- /dev/null +++ b/data/web/inc/lib/vendor/illuminate/contracts/Support/CanBeEscapedWhenCastToString.php @@ -0,0 +1,14 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon\PHPStan; + +if (!class_exists(LazyMacro::class, false)) { + abstract class LazyMacro extends AbstractMacro + { + /** + * {@inheritdoc} + */ + public function getFileName(): ?string + { + return $this->reflectionFunction->getFileName(); + } + + /** + * {@inheritdoc} + */ + public function getStartLine(): ?int + { + return $this->reflectionFunction->getStartLine(); + } + + /** + * {@inheritdoc} + */ + public function getEndLine(): ?int + { + return $this->reflectionFunction->getEndLine(); + } + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php b/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php new file mode 100644 index 00000000..3e9fcf4f --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php @@ -0,0 +1,49 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon\PHPStan; + +if (!class_exists(LazyMacro::class, false)) { + abstract class LazyMacro extends AbstractMacro + { + /** + * {@inheritdoc} + * + * @return string|false + */ + public function getFileName() + { + return $this->reflectionFunction->getFileName(); + } + + /** + * {@inheritdoc} + * + * @return int|false + */ + public function getStartLine() + { + return $this->reflectionFunction->getStartLine(); + } + + /** + * {@inheritdoc} + * + * @return int|false + */ + public function getEndLine() + { + return $this->reflectionFunction->getEndLine(); + } + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/TranslatorStrongType.php b/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/TranslatorStrongType.php new file mode 100644 index 00000000..d35308a6 --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/TranslatorStrongType.php @@ -0,0 +1,52 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon; + +use Symfony\Component\Translation\MessageCatalogueInterface; + +if (!class_exists(LazyTranslator::class, false)) { + class LazyTranslator extends AbstractTranslator implements TranslatorStrongTypeInterface + { + public function trans(?string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string + { + return $this->translate($id, $parameters, $domain, $locale); + } + + public function getFromCatalogue(MessageCatalogueInterface $catalogue, string $id, string $domain = 'messages') + { + $messages = $this->getPrivateProperty($catalogue, 'messages'); + + if (isset($messages[$domain.MessageCatalogueInterface::INTL_DOMAIN_SUFFIX][$id])) { + return $messages[$domain.MessageCatalogueInterface::INTL_DOMAIN_SUFFIX][$id]; + } + + if (isset($messages[$domain][$id])) { + return $messages[$domain][$id]; + } + + $fallbackCatalogue = $this->getPrivateProperty($catalogue, 'fallbackCatalogue'); + + if ($fallbackCatalogue !== null) { + return $this->getFromCatalogue($fallbackCatalogue, $id, $domain); + } + + return $id; + } + + private function getPrivateProperty($instance, string $field) + { + return (function (string $field) { + return $this->$field; + })->call($instance, $field); + } + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/TranslatorWeakType.php b/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/TranslatorWeakType.php new file mode 100644 index 00000000..94dbdc30 --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/TranslatorWeakType.php @@ -0,0 +1,32 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon; + +if (!class_exists(LazyTranslator::class, false)) { + class LazyTranslator extends AbstractTranslator + { + /** + * Returns the translation. + * + * @param string|null $id + * @param array $parameters + * @param string|null $domain + * @param string|null $locale + * + * @return string + */ + public function trans($id, array $parameters = [], $domain = null, $locale = null) + { + return $this->translate($id, $parameters, $domain, $locale); + } + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/readme.md b/data/web/inc/lib/vendor/nesbot/carbon/readme.md index 70279c1e..5d827219 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/readme.md +++ b/data/web/inc/lib/vendor/nesbot/carbon/readme.md @@ -3,9 +3,7 @@ [![Latest Stable Version](https://img.shields.io/packagist/v/nesbot/carbon.svg?style=flat-square)](https://packagist.org/packages/nesbot/carbon) [![Total Downloads](https://img.shields.io/packagist/dt/nesbot/carbon.svg?style=flat-square)](https://packagist.org/packages/nesbot/carbon) [![GitHub Actions](https://img.shields.io/endpoint.svg?url=https%3A%2F%2Factions-badge.atrox.dev%2Fbriannesbitt%2FCarbon%2Fbadge&style=flat-square&label=Build&logo=none)](https://actions-badge.atrox.dev/briannesbitt/Carbon/goto) -[![StyleCI](https://github.styleci.io/repos/5724990/shield?style=flat-square)](https://github.styleci.io/repos/5724990) [![codecov.io](https://img.shields.io/codecov/c/github/briannesbitt/Carbon.svg?style=flat-square)](https://codecov.io/github/briannesbitt/Carbon?branch=master) -[![PHPStan](https://img.shields.io/badge/PHPStan-enabled-44CC11.svg?longCache=true&style=flat-square)](https://github.com/phpstan/phpstan) [![Tidelift](https://tidelift.com/badges/github/briannesbitt/Carbon)](https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme) An international PHP extension for DateTime. [https://carbon.nesbot.com](https://carbon.nesbot.com) diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php new file mode 100644 index 00000000..48441e7c --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php @@ -0,0 +1,401 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon; + +use Closure; +use ReflectionException; +use ReflectionFunction; +use Symfony\Component\Translation; +use Symfony\Component\Translation\Formatter\MessageFormatterInterface; +use Symfony\Component\Translation\Loader\ArrayLoader; + +abstract class AbstractTranslator extends Translation\Translator +{ + /** + * Translator singletons for each language. + * + * @var array + */ + protected static $singletons = []; + + /** + * List of custom localized messages. + * + * @var array + */ + protected $messages = []; + + /** + * List of custom directories that contain translation files. + * + * @var string[] + */ + protected $directories = []; + + /** + * Set to true while constructing. + * + * @var bool + */ + protected $initializing = false; + + /** + * List of locales aliases. + * + * @var string[] + */ + protected $aliases = [ + 'me' => 'sr_Latn_ME', + 'scr' => 'sh', + ]; + + /** + * Return a singleton instance of Translator. + * + * @param string|null $locale optional initial locale ("en" - english by default) + * + * @return static + */ + public static function get($locale = null) + { + $locale = $locale ?: 'en'; + $key = static::class === Translator::class ? $locale : static::class.'|'.$locale; + + if (!isset(static::$singletons[$key])) { + static::$singletons[$key] = new static($locale); + } + + return static::$singletons[$key]; + } + + public function __construct($locale, MessageFormatterInterface $formatter = null, $cacheDir = null, $debug = false) + { + parent::setLocale($locale); + $this->initializing = true; + $this->directories = [__DIR__.'/Lang']; + $this->addLoader('array', new ArrayLoader()); + parent::__construct($locale, $formatter, $cacheDir, $debug); + $this->initializing = false; + } + + /** + * Returns the list of directories translation files are searched in. + * + * @return array + */ + public function getDirectories(): array + { + return $this->directories; + } + + /** + * Set list of directories translation files are searched in. + * + * @param array $directories new directories list + * + * @return $this + */ + public function setDirectories(array $directories) + { + $this->directories = $directories; + + return $this; + } + + /** + * Add a directory to the list translation files are searched in. + * + * @param string $directory new directory + * + * @return $this + */ + public function addDirectory(string $directory) + { + $this->directories[] = $directory; + + return $this; + } + + /** + * Remove a directory from the list translation files are searched in. + * + * @param string $directory directory path + * + * @return $this + */ + public function removeDirectory(string $directory) + { + $search = rtrim(strtr($directory, '\\', '/'), '/'); + + return $this->setDirectories(array_filter($this->getDirectories(), function ($item) use ($search) { + return rtrim(strtr($item, '\\', '/'), '/') !== $search; + })); + } + + /** + * Reset messages of a locale (all locale if no locale passed). + * Remove custom messages and reload initial messages from matching + * file in Lang directory. + * + * @param string|null $locale + * + * @return bool + */ + public function resetMessages($locale = null) + { + if ($locale === null) { + $this->messages = []; + + return true; + } + + foreach ($this->getDirectories() as $directory) { + $data = @include sprintf('%s/%s.php', rtrim($directory, '\\/'), $locale); + + if ($data !== false) { + $this->messages[$locale] = $data; + $this->addResource('array', $this->messages[$locale], $locale); + + return true; + } + } + + return false; + } + + /** + * Returns the list of files matching a given locale prefix (or all if empty). + * + * @param string $prefix prefix required to filter result + * + * @return array + */ + public function getLocalesFiles($prefix = '') + { + $files = []; + + foreach ($this->getDirectories() as $directory) { + $directory = rtrim($directory, '\\/'); + + foreach (glob("$directory/$prefix*.php") as $file) { + $files[] = $file; + } + } + + return array_unique($files); + } + + /** + * Returns the list of internally available locales and already loaded custom locales. + * (It will ignore custom translator dynamic loading.) + * + * @param string $prefix prefix required to filter result + * + * @return array + */ + public function getAvailableLocales($prefix = '') + { + $locales = []; + foreach ($this->getLocalesFiles($prefix) as $file) { + $locales[] = substr($file, strrpos($file, '/') + 1, -4); + } + + return array_unique(array_merge($locales, array_keys($this->messages))); + } + + protected function translate(?string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string + { + if ($domain === null) { + $domain = 'messages'; + } + + $catalogue = $this->getCatalogue($locale); + $format = $this instanceof TranslatorStrongTypeInterface + ? $this->getFromCatalogue($catalogue, (string) $id, $domain) // @codeCoverageIgnore + : $this->getCatalogue($locale)->get((string) $id, $domain); + + if ($format instanceof Closure) { + // @codeCoverageIgnoreStart + try { + $count = (new ReflectionFunction($format))->getNumberOfRequiredParameters(); + } catch (ReflectionException $exception) { + $count = 0; + } + // @codeCoverageIgnoreEnd + + return $format( + ...array_values($parameters), + ...array_fill(0, max(0, $count - \count($parameters)), null) + ); + } + + return parent::trans($id, $parameters, $domain, $locale); + } + + /** + * Init messages language from matching file in Lang directory. + * + * @param string $locale + * + * @return bool + */ + protected function loadMessagesFromFile($locale) + { + if (isset($this->messages[$locale])) { + return true; + } + + return $this->resetMessages($locale); + } + + /** + * Set messages of a locale and take file first if present. + * + * @param string $locale + * @param array $messages + * + * @return $this + */ + public function setMessages($locale, $messages) + { + $this->loadMessagesFromFile($locale); + $this->addResource('array', $messages, $locale); + $this->messages[$locale] = array_merge( + $this->messages[$locale] ?? [], + $messages + ); + + return $this; + } + + /** + * Set messages of the current locale and take file first if present. + * + * @param array $messages + * + * @return $this + */ + public function setTranslations($messages) + { + return $this->setMessages($this->getLocale(), $messages); + } + + /** + * Get messages of a locale, if none given, return all the + * languages. + * + * @param string|null $locale + * + * @return array + */ + public function getMessages($locale = null) + { + return $locale === null ? $this->messages : $this->messages[$locale]; + } + + /** + * Set the current translator locale and indicate if the source locale file exists + * + * @param string $locale locale ex. en + * + * @return bool + */ + public function setLocale($locale) + { + $locale = preg_replace_callback('/[-_]([a-z]{2,}|[0-9]{2,})/', function ($matches) { + // _2-letters or YUE is a region, _3+-letters is a variant + $upper = strtoupper($matches[1]); + + if ($upper === 'YUE' || $upper === 'ISO' || \strlen($upper) < 3) { + return "_$upper"; + } + + return '_'.ucfirst($matches[1]); + }, strtolower($locale)); + + $previousLocale = $this->getLocale(); + + if ($previousLocale === $locale && isset($this->messages[$locale])) { + return true; + } + + unset(static::$singletons[$previousLocale]); + + if ($locale === 'auto') { + $completeLocale = setlocale(LC_TIME, '0'); + $locale = preg_replace('/^([^_.-]+).*$/', '$1', $completeLocale); + $locales = $this->getAvailableLocales($locale); + + $completeLocaleChunks = preg_split('/[_.-]+/', $completeLocale); + + $getScore = function ($language) use ($completeLocaleChunks) { + return self::compareChunkLists($completeLocaleChunks, preg_split('/[_.-]+/', $language)); + }; + + usort($locales, function ($first, $second) use ($getScore) { + return $getScore($second) <=> $getScore($first); + }); + + $locale = $locales[0]; + } + + if (isset($this->aliases[$locale])) { + $locale = $this->aliases[$locale]; + } + + // If subtag (ex: en_CA) first load the macro (ex: en) to have a fallback + if (str_contains($locale, '_') && + $this->loadMessagesFromFile($macroLocale = preg_replace('/^([^_]+).*$/', '$1', $locale)) + ) { + parent::setLocale($macroLocale); + } + + if ($this->loadMessagesFromFile($locale) || $this->initializing) { + parent::setLocale($locale); + + return true; + } + + return false; + } + + /** + * Show locale on var_dump(). + * + * @return array + */ + public function __debugInfo() + { + return [ + 'locale' => $this->getLocale(), + ]; + } + + private static function compareChunkLists($referenceChunks, $chunks) + { + $score = 0; + + foreach ($referenceChunks as $index => $chunk) { + if (!isset($chunks[$index])) { + $score++; + + continue; + } + + if (strtolower($chunks[$index]) === strtolower($chunk)) { + $score += 10; + } + } + + return $score; + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php index 3b687591..e327590e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php @@ -8,9 +8,11 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Carbon\Traits\Date; +use Carbon\Traits\DeprecatedProperties; use DateTime; use DateTimeInterface; use DateTimeZone; @@ -18,6 +20,8 @@ use DateTimeZone; /** * A simple API extension for DateTime. * + * @mixin DeprecatedProperties + * * * * @property int $year @@ -34,10 +38,6 @@ use DateTimeZone; * @property string $shortEnglishDayOfWeek the abbreviated day of week in English * @property string $englishMonth the month in English * @property string $shortEnglishMonth the abbreviated month in English - * @property string $localeDayOfWeek the day of week in current locale LC_TIME - * @property string $shortLocaleDayOfWeek the abbreviated day of week in current locale LC_TIME - * @property string $localeMonth the month in current locale LC_TIME - * @property string $shortLocaleMonth the abbreviated month in current locale LC_TIME * @property int $milliseconds * @property int $millisecond * @property int $milli diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonConverterInterface.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonConverterInterface.php index eb0a7093..1ce967b2 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonConverterInterface.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonConverterInterface.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use DateTimeInterface; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php index cb1c4988..6d1194ee 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php @@ -8,9 +8,11 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Carbon\Traits\Date; +use Carbon\Traits\DeprecatedProperties; use DateTimeImmutable; use DateTimeInterface; use DateTimeZone; @@ -18,6 +20,8 @@ use DateTimeZone; /** * A simple API extension for DateTimeImmutable. * + * @mixin DeprecatedProperties + * * * * @property int $year @@ -34,10 +38,6 @@ use DateTimeZone; * @property string $shortEnglishDayOfWeek the abbreviated day of week in English * @property string $englishMonth the month in English * @property string $shortEnglishMonth the abbreviated month in English - * @property string $localeDayOfWeek the day of week in current locale LC_TIME - * @property string $shortLocaleDayOfWeek the abbreviated day of week in current locale LC_TIME - * @property string $localeMonth the month in current locale LC_TIME - * @property string $shortLocaleMonth the abbreviated month in current locale LC_TIME * @property int $milliseconds * @property int $millisecond * @property int $milli diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php index 8f095072..15e2061c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use BadMethodCallException; @@ -27,6 +28,7 @@ use DateTimeZone; use JsonSerializable; use ReflectionException; use ReturnTypeWillChange; +use Symfony\Component\Translation\TranslatorInterface; use Throwable; /** @@ -48,10 +50,6 @@ use Throwable; * @property string $shortEnglishDayOfWeek the abbreviated day of week in English * @property string $englishMonth the month in English * @property string $shortEnglishMonth the abbreviated month in English - * @property string $localeDayOfWeek the day of week in current locale LC_TIME - * @property string $shortLocaleDayOfWeek the abbreviated day of week in current locale LC_TIME - * @property string $localeMonth the month in current locale LC_TIME - * @property string $shortLocaleMonth the abbreviated month in current locale LC_TIME * @property int $milliseconds * @property int $millisecond * @property int $milli @@ -1270,7 +1268,8 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable /** * Get the difference as a CarbonInterval instance. - * Return absolute interval (always positive) unless you pass false to the second argument. + * Return relative interval (negative if $absolute flag is not set to true and the given date is before + * current one). * * @param \Carbon\CarbonInterface|\DateTimeInterface|string|null $date * @param bool $absolute Get the absolute of the difference @@ -1312,6 +1311,10 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * - 'short' entry (see below) * - 'parts' entry (see below) * - 'options' entry (see below) + * - 'skip' entry, list of units to skip (array of strings or a single string, + * ` it can be the unit name (singular or plural) or its shortcut + * ` (y, m, w, d, h, min, s, ms, µs). + * - 'aUnit' entry, prefer "an hour" over "1 hour" if true * - 'join' entry determines how to join multiple parts of the string * ` - if $join is a string, it's used as a joiner glue * ` - if $join is a callable/closure, it get the list of string and should return a string @@ -1320,6 +1323,8 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * ` - if $join is true, it will be guessed from the locale ('list' translation file entry) * ` - if $join is missing, a space will be used as glue * - 'other' entry (see above) + * - 'minimumUnit' entry determines the smallest unit of time to display can be long or + * ` short form of the units, e.g. 'hour' or 'h' (default value: s) * if int passed, it add modifiers: * Possible values: * - CarbonInterface::DIFF_ABSOLUTE no modifiers @@ -1962,6 +1967,10 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * Format the instance with the current locale. You can set the current * locale using setlocale() https://php.net/setlocale. * + * @deprecated It uses OS language package and strftime() which is deprecated since PHP 8.1. + * Use ->isoFormat() instead. + * Deprecated since 2.55.0 + * * @param string $format * * @return string @@ -2148,6 +2157,8 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable /** * {@inheritdoc} + * + * @return array */ #[ReturnTypeWillChange] public static function getLastErrors(); @@ -2259,6 +2270,13 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable */ public static function getTimeFormatByPrecision($unitPrecision); + /** + * Returns the timestamp with millisecond precision. + * + * @return int + */ + public function getTimestampMs(); + /** * Get the translation of the current week day name (with context for languages with multiple forms). * @@ -3332,6 +3350,8 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * Calls \DateTime::modify if mutable or \DateTimeImmutable::modify else. * * @see https://php.net/manual/en/datetime.modify.php + * + * @return static|false */ #[ReturnTypeWillChange] public function modify($modify); @@ -3792,7 +3812,7 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * * @return $this */ - public function setLocalTranslator(\Symfony\Component\Translation\TranslatorInterface $translator); + public function setLocalTranslator(TranslatorInterface $translator); /** * Set the current translator locale and indicate if the source locale file exists. @@ -3832,6 +3852,9 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * Note the timezone parameter was left out of the examples above and * has no affect as the mock value will be returned regardless of its value. * + * Only the moment is mocked with setTestNow(), the timezone will still be the one passed + * as parameter of date_default_timezone_get() as a fallback (see setTestNowAndTimezone()). + * * To clear the test instance call this method using the default * parameter of null. * @@ -3841,6 +3864,27 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable */ public static function setTestNow($testNow = null); + /** + * Set a Carbon instance (real or mock) to be returned when a "now" + * instance is created. The provided instance will be returned + * specifically under the following conditions: + * - A call to the static now() method, ex. Carbon::now() + * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) + * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') + * - When a string containing the desired time is passed to Carbon::parse(). + * + * It will also align default timezone (e.g. call date_default_timezone_set()) with + * the second argument or if null, with the timezone of the given date object. + * + * To clear the test instance call this method using the default + * parameter of null. + * + * /!\ Use this method for unit tests only. + * + * @param Closure|static|string|false|null $testNow real or mock Carbon instance + */ + public static function setTestNowAndTimezone($testNow = null, $tz = null); + /** * Resets the current time of the DateTime object to a different time. * @@ -3917,7 +3961,7 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * * @return void */ - public static function setTranslator(\Symfony\Component\Translation\TranslatorInterface $translator); + public static function setTranslator(TranslatorInterface $translator); /** * Set specified unit to new given value. @@ -4772,14 +4816,15 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable /** * Translate using translation string or callback available. * - * @param string $key - * @param array $parameters - * @param string|int|float|null $number - * @param \Symfony\Component\Translation\TranslatorInterface $translator + * @param string $key + * @param array $parameters + * @param string|int|float|null $number + * @param \Symfony\Component\Translation\TranslatorInterface|null $translator + * @param bool $altNumbers * * @return string */ - public function translate(string $key, array $parameters = [], $number = null, ?\Symfony\Component\Translation\TranslatorInterface $translator = null, bool $altNumbers = false): string; + public function translate(string $key, array $parameters = [], $number = null, ?TranslatorInterface $translator = null, bool $altNumbers = false): string; /** * Returns the alternative number for a given integer if available in the current locale. @@ -4828,7 +4873,7 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * * @return string */ - public static function translateWith(\Symfony\Component\Translation\TranslatorInterface $translator, string $key, array $parameters = [], $number = null): string; + public static function translateWith(TranslatorInterface $translator, string $key, array $parameters = [], $number = null): string; /** * Format as ->format() do (using date replacements patterns from https://php.net/manual/en/function.date.php) @@ -5012,8 +5057,8 @@ interface CarbonInterface extends DateTimeInterface, JsonSerializable * * /!\ Use this method for unit tests only. * - * @param Closure|static|string|false|null $testNow real or mock Carbon instance - * @param Closure|null $callback + * @param Closure|static|string|false|null $testNow real or mock Carbon instance + * @param Closure|null $callback * * @return mixed */ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php index 7168fa4b..d465beac 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Carbon\Exceptions\BadFluentConstructorException; @@ -25,6 +26,8 @@ use Carbon\Traits\Mixin; use Carbon\Traits\Options; use Closure; use DateInterval; +use DateTimeInterface; +use DateTimeZone; use Exception; use ReflectionException; use ReturnTypeWillChange; @@ -189,14 +192,14 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface /** * Interval spec period designators */ - const PERIOD_PREFIX = 'P'; - const PERIOD_YEARS = 'Y'; - const PERIOD_MONTHS = 'M'; - const PERIOD_DAYS = 'D'; - const PERIOD_TIME_PREFIX = 'T'; - const PERIOD_HOURS = 'H'; - const PERIOD_MINUTES = 'M'; - const PERIOD_SECONDS = 'S'; + public const PERIOD_PREFIX = 'P'; + public const PERIOD_YEARS = 'Y'; + public const PERIOD_MONTHS = 'M'; + public const PERIOD_DAYS = 'D'; + public const PERIOD_TIME_PREFIX = 'T'; + public const PERIOD_HOURS = 'H'; + public const PERIOD_MINUTES = 'M'; + public const PERIOD_SECONDS = 'S'; /** * A translator to ... er ... translate stuff @@ -253,6 +256,22 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface protected $tzName; /** + * Set the instance's timezone from a string or object. + * + * @param \DateTimeZone|string $tzName + * + * @return static + */ + public function setTimezone($tzName) + { + $this->tzName = $tzName; + + return $this; + } + + /** + * @internal + * * Set the instance's timezone from a string or object and add/subtract the offset difference. * * @param \DateTimeZone|string $tzName @@ -346,7 +365,7 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface if ($years instanceof DateInterval) { parent::__construct(static::getDateIntervalSpec($years)); $this->f = $years->f; - static::copyNegativeUnits($years, $this); + self::copyNegativeUnits($years, $this); return; } @@ -397,7 +416,7 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface { $source = self::standardizeUnit($source); $target = self::standardizeUnit($target); - $factors = static::getFlipCascadeFactors(); + $factors = self::getFlipCascadeFactors(); if (isset($factors[$source])) { [$to, $factor] = $factors[$source]; @@ -412,6 +431,37 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface return null; } + /** + * Returns the factor for a given source-to-target couple if set, + * else try to find the appropriate constant as the factor, such as Carbon::DAYS_PER_WEEK. + * + * @param string $source + * @param string $target + * + * @return int|null + */ + public static function getFactorWithDefault($source, $target) + { + $factor = self::getFactor($source, $target); + + if ($factor) { + return $factor; + } + + static $defaults = [ + 'month' => ['year' => Carbon::MONTHS_PER_YEAR], + 'week' => ['month' => Carbon::WEEKS_PER_MONTH], + 'day' => ['week' => Carbon::DAYS_PER_WEEK], + 'hour' => ['day' => Carbon::HOURS_PER_DAY], + 'minute' => ['hour' => Carbon::MINUTES_PER_HOUR], + 'second' => ['minute' => Carbon::SECONDS_PER_MINUTE], + 'millisecond' => ['second' => Carbon::MILLISECONDS_PER_SECOND], + 'microsecond' => ['millisecond' => Carbon::MICROSECONDS_PER_MILLISECOND], + ]; + + return $defaults[$source][$target] ?? null; + } + /** * Returns current config for days per week. * @@ -504,10 +554,10 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface * echo Carboninterval::createFromFormat('H:i', '1:30'); * ``` * - * @param string $format Format of the $interval input string - * @param string $interval Input string to convert into an interval + * @param string $format Format of the $interval input string + * @param string|null $interval Input string to convert into an interval * - * @throws Exception when the $interval cannot be parsed as an interval. + * @throws \Carbon\Exceptions\ParseErrorException when the $interval cannot be parsed as an interval. * * @return static */ @@ -848,10 +898,10 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface } if ($interval instanceof self && is_a($className, self::class, true)) { - static::copyStep($interval, $instance); + self::copyStep($interval, $instance); } - static::copyNegativeUnits($interval, $instance); + self::copyNegativeUnits($interval, $instance); return $instance; } @@ -1358,7 +1408,11 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface $altNumbers = false; $aUnit = false; $minimumUnit = 's'; + $skip = []; extract($this->getForHumansInitialVariables($syntax, $short)); + $skip = array_filter((array) $skip, static function ($value) { + return \is_string($value) && $value !== ''; + }); if ($syntax === null) { $syntax = CarbonInterface::DIFF_ABSOLUTE; @@ -1421,7 +1475,7 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface ':optional-space' => $optionalSpace, ]; - return [$syntax, $short, $parts, $options, $join, $aUnit, $altNumbers, $interpolations, $minimumUnit]; + return [$syntax, $short, $parts, $options, $join, $aUnit, $altNumbers, $interpolations, $minimumUnit, $skip]; } protected static function getRoundingMethodFromOptions(int $options): ?string @@ -1525,6 +1579,9 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface * - 'short' entry (see below) * - 'parts' entry (see below) * - 'options' entry (see below) + * - 'skip' entry, list of units to skip (array of strings or a single string, + * ` it can be the unit name (singular or plural) or its shortcut + * ` (y, m, w, d, h, min, s, ms, µs). * - 'aUnit' entry, prefer "an hour" over "1 hour" if true * - 'join' entry determines how to join multiple parts of the string * ` - if $join is a string, it's used as a joiner glue @@ -1551,11 +1608,12 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface */ public function forHumans($syntax = null, $short = false, $parts = -1, $options = null) { - [$syntax, $short, $parts, $options, $join, $aUnit, $altNumbers, $interpolations, $minimumUnit] = $this->getForHumansParameters($syntax, $short, $parts, $options); + [$syntax, $short, $parts, $options, $join, $aUnit, $altNumbers, $interpolations, $minimumUnit, $skip] = $this + ->getForHumansParameters($syntax, $short, $parts, $options); $interval = []; - $syntax = (int) ($syntax === null ? CarbonInterface::DIFF_ABSOLUTE : $syntax); + $syntax = (int) ($syntax ?? CarbonInterface::DIFF_ABSOLUTE); $absolute = $syntax === CarbonInterface::DIFF_ABSOLUTE; $relativeToNow = $syntax === CarbonInterface::DIFF_RELATIVE_TO_NOW; $count = 1; @@ -1596,8 +1654,14 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface \count($intervalValues->getNonZeroValues()) > $parts && ($count = \count($keys = array_keys($intervalValues->getValuesSequence()))) > 1 ) { + $index = min($count, $previousCount - 1) - 2; + + if ($index < 0) { + break; + } + $intervalValues = $this->copy()->roundUnit( - $keys[min($count, $previousCount - 1) - 2], + $keys[$index], 1, $method ); @@ -1617,6 +1681,21 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface ['value' => $intervalValues->microExcludeMilli, 'unit' => 'microsecond', 'unitShort' => 'µs'], ]; + if (!empty($skip)) { + foreach ($diffIntervalArray as $index => &$unitData) { + $nextIndex = $index + 1; + + if ($unitData['value'] && + isset($diffIntervalArray[$nextIndex]) && + \count(array_intersect([$unitData['unit'], $unitData['unit'].'s', $unitData['unitShort']], $skip)) + ) { + $diffIntervalArray[$nextIndex]['value'] += $unitData['value'] * + self::getFactorWithDefault($diffIntervalArray[$nextIndex]['unit'], $unitData['unit']); + $unitData['value'] = 0; + } + } + } + $transChoice = function ($short, $unitData) use ($absolute, $handleDeclensions, $translator, $aUnit, $altNumbers, $interpolations) { $count = $unitData['value']; @@ -1642,6 +1721,7 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface }; $fallbackUnit = ['second', 's']; + foreach ($diffIntervalArray as $diffIntervalData) { if ($diffIntervalData['value'] > 0) { $unit = $short ? $diffIntervalData['unitShort'] : $diffIntervalData['unit']; @@ -1763,12 +1843,20 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface /** * Convert the interval to a CarbonPeriod. * - * @param array ...$params Start date, [end date or recurrences] and optional settings. + * @param DateTimeInterface|string|int ...$params Start date, [end date or recurrences] and optional settings. * * @return CarbonPeriod */ public function toPeriod(...$params) { + if ($this->tzName) { + $tz = \is_string($this->tzName) ? new DateTimeZone($this->tzName) : $this->tzName; + + if ($tz instanceof DateTimeZone) { + array_unshift($params, $tz); + } + } + return CarbonPeriod::create($this, ...$params); } @@ -1879,8 +1967,8 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface /** * Add given parameters to the current interval. * - * @param int $years - * @param int $months + * @param int $years + * @param int $months * @param int|float $weeks * @param int|float $days * @param int|float $hours @@ -1909,8 +1997,8 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface /** * Add given parameters to the current interval. * - * @param int $years - * @param int $months + * @param int $years + * @param int $months * @param int|float $weeks * @param int|float $days * @param int|float $hours @@ -2145,7 +2233,7 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface unset($originalData['days']); $newData = $originalData; - foreach (static::getFlipCascadeFactors() as $source => [$target, $factor]) { + foreach (self::getFlipCascadeFactors() as $source => [$target, $factor]) { foreach (['source', 'target'] as $key) { if ($$key === 'dayz') { $$key = 'daysExcludeWeeks'; @@ -2235,7 +2323,7 @@ class CarbonInterval extends DateInterval implements CarbonConverterInterface $result = 0; $cumulativeFactor = 0; $unitFound = false; - $factors = static::getFlipCascadeFactors(); + $factors = self::getFlipCascadeFactors(); $daysPerWeek = static::getDaysPerWeek(); $values = [ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php index 70e6ba49..0e81e757 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Carbon\Exceptions\InvalidCastException; @@ -28,6 +29,7 @@ use DateInterval; use DatePeriod; use DateTime; use DateTimeInterface; +use DateTimeZone; use InvalidArgumentException; use Iterator; use JsonSerializable; @@ -161,6 +163,8 @@ use RuntimeException; * @method $this floorMicroseconds(float $precision = 1) Truncate the current instance microsecond with given precision. * @method $this ceilMicrosecond(float $precision = 1) Ceil the current instance microsecond with given precision. * @method $this ceilMicroseconds(float $precision = 1) Ceil the current instance microsecond with given precision. + * + * @SuppressWarnings(PHPMD.CouplingBetweenObjects) */ class CarbonPeriod implements Iterator, Countable, JsonSerializable { @@ -171,17 +175,23 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable use Options; /** - * Built-in filters. + * Built-in filter for limit by recurrences. * - * @var string + * @var callable */ public const RECURRENCES_FILTER = [self::class, 'filterRecurrences']; + + /** + * Built-in filter for limit to an end. + * + * @var callable + */ public const END_DATE_FILTER = [self::class, 'filterEndDate']; /** * Special value which can be returned by filters to end iteration. Also a filter. * - * @var string + * @var callable */ public const END_ITERATION = [self::class, 'endIteration']; @@ -474,8 +484,8 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable $end = null; foreach (explode('/', $iso) as $key => $part) { - if ($key === 0 && preg_match('/^R([0-9]*)$/', $part, $match)) { - $parsed = \strlen($match[1]) ? (int) $match[1] : null; + if ($key === 0 && preg_match('/^R([0-9]*|INF)$/', $part, $match)) { + $parsed = \strlen($match[1]) ? (($match[1] !== 'INF') ? (int) $match[1] : INF) : null; } elseif ($interval === null && $parsed = CarbonInterval::make($part)) { $interval = $part; } elseif ($start === null && $parsed = Carbon::make($part)) { @@ -639,7 +649,11 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable } foreach ($arguments as $argument) { - if ($this->dateInterval === null && + $parsedDate = null; + + if ($argument instanceof DateTimeZone) { + $this->setTimezone($argument); + } elseif ($this->dateInterval === null && ( \is_string($argument) && preg_match( '/^(-?\d(\d(?![\/-])|[^\d\/-]([\/-])?)*|P[T0-9].*|(?:\h*\d+(?:\.\d+)?\h*[a-z]+)+)$/i', @@ -648,13 +662,13 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable $argument instanceof DateInterval || $argument instanceof Closure ) && - $parsed = @CarbonInterval::make($argument) + $parsedInterval = @CarbonInterval::make($argument) ) { - $this->setDateInterval($parsed); - } elseif ($this->startDate === null && $parsed = Carbon::make($argument)) { - $this->setStartDate($parsed); - } elseif ($this->endDate === null && $parsed = Carbon::make($argument)) { - $this->setEndDate($parsed); + $this->setDateInterval($parsedInterval); + } elseif ($this->startDate === null && $parsedDate = $this->makeDateTime($argument)) { + $this->setStartDate($parsedDate); + } elseif ($this->endDate === null && ($parsedDate = $parsedDate ?? $this->makeDateTime($argument))) { + $this->setEndDate($parsedDate); } elseif ($this->recurrences === null && $this->endDate === null && is_numeric($argument)) { $this->setRecurrences($argument); } elseif ($this->options === null && (\is_int($argument) || $argument === null)) { @@ -1305,6 +1319,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable * * @return bool */ + #[ReturnTypeWillChange] public function valid() { return $this->validateCurrentDate() === true; @@ -1315,6 +1330,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable * * @return int|null */ + #[ReturnTypeWillChange] public function key() { return $this->valid() @@ -1327,6 +1343,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable * * @return CarbonInterface|null */ + #[ReturnTypeWillChange] public function current() { return $this->valid() @@ -1341,6 +1358,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable * * @return void */ + #[ReturnTypeWillChange] public function next() { if ($this->current === null) { @@ -1367,6 +1385,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable * * @return void */ + #[ReturnTypeWillChange] public function rewind() { $this->key = 0; @@ -1540,6 +1559,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable * * @return int */ + #[ReturnTypeWillChange] public function count() { return \count($this->toArray()); @@ -1615,14 +1635,14 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable return $this->setStartDate($first, $second); case 'sinceNow': - return $this->setStartDate(new Carbon, $first); + return $this->setStartDate(new Carbon(), $first); case 'end': case 'until': return $this->setEndDate($first, $second); case 'untilNow': - return $this->setEndDate(new Carbon, $first); + return $this->setEndDate(new Carbon(), $first); case 'dates': case 'between': @@ -1689,7 +1709,30 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable } /** - * Set the instance's timezone from a string or object and add/subtract the offset difference. + * Set the instance's timezone from a string or object and apply it to start/end. + * + * @param \DateTimeZone|string $timezone + * + * @return static + */ + public function setTimezone($timezone) + { + $this->tzName = $timezone; + $this->timezone = $timezone; + + if ($this->startDate) { + $this->setStartDate($this->startDate->setTimezone($timezone)); + } + + if ($this->endDate) { + $this->setEndDate($this->endDate->setTimezone($timezone)); + } + + return $this; + } + + /** + * Set the instance's timezone from a string or object and add/subtract the offset difference to start/end. * * @param \DateTimeZone|string $timezone * @@ -1700,6 +1743,14 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable $this->tzName = $timezone; $this->timezone = $timezone; + if ($this->startDate) { + $this->setStartDate($this->startDate->shiftTimezone($timezone)); + } + + if ($this->endDate) { + $this->setEndDate($this->endDate->shiftTimezone($timezone)); + } + return $this; } @@ -2130,7 +2181,10 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable */ public function round($precision = null, $function = 'round') { - return $this->roundWith($precision ?? (string) $this->getDateInterval(), $function); + return $this->roundWith( + $precision ?? $this->getDateInterval()->setLocalTranslator(TranslatorImmutable::get('en'))->forHumans(), + $function + ); } /** @@ -2362,11 +2416,7 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable } // Check after the first rewind to avoid repeating the initial validation. - if ($this->validationResult !== null) { - return $this->validationResult; - } - - return $this->validationResult = $this->checkFilters(); + return $this->validationResult ?? ($this->validationResult = $this->checkFilters()); } /** @@ -2495,4 +2545,24 @@ class CarbonPeriod implements Iterator, Countable, JsonSerializable { return $first > $second ? [$second, $first] : [$first, $second]; } + + private function makeDateTime($value): ?DateTimeInterface + { + if ($value instanceof DateTimeInterface) { + return $value; + } + + if (\is_string($value)) { + $value = trim($value); + + if (!preg_match('/^P[0-9T]/', $value) && + !preg_match('/^R[0-9]/', $value) && + preg_match('/[a-z0-9]/i', $value) + ) { + return Carbon::parse($value, $this->tzName); + } + } + + return null; + } } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php index 2bd36c43..b4d16ba9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php @@ -8,12 +8,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Carbon\Exceptions\InvalidCastException; use Carbon\Exceptions\InvalidTimeZoneException; use DateTimeInterface; use DateTimeZone; +use Throwable; class CarbonTimeZone extends DateTimeZone { @@ -198,7 +200,7 @@ class CarbonTimeZone extends DateTimeZone // @codeCoverageIgnoreStart try { $offset = @$this->getOffset($date) ?: 0; - } catch (\Throwable $e) { + } catch (Throwable $e) { $offset = 0; } // @codeCoverageIgnoreEnd diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Cli/Invoker.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Cli/Invoker.php index d53b1f49..4f35d6c6 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Cli/Invoker.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Cli/Invoker.php @@ -1,5 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + namespace Carbon\Cli; class Invoker diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php index 35c5558a..ccc457fc 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php @@ -1,9 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. */ + namespace Carbon\Doctrine; use Doctrine\DBAL\Platforms\AbstractPlatform; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php index 32397434..bf476a77 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php @@ -1,9 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. */ + namespace Carbon\Doctrine; use Doctrine\DBAL\Platforms\AbstractPlatform; @@ -12,6 +17,8 @@ class CarbonImmutableType extends DateTimeImmutableType implements CarbonDoctrin { /** * {@inheritdoc} + * + * @return string */ public function getName() { @@ -20,6 +27,8 @@ class CarbonImmutableType extends DateTimeImmutableType implements CarbonDoctrin /** * {@inheritdoc} + * + * @return bool */ public function requiresSQLCommentHint(AbstractPlatform $platform) { diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php index e5f52c7d..9289d84d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php @@ -1,9 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. */ + namespace Carbon\Doctrine; use Doctrine\DBAL\Platforms\AbstractPlatform; @@ -12,6 +17,8 @@ class CarbonType extends DateTimeType implements CarbonDoctrineType { /** * {@inheritdoc} + * + * @return string */ public function getName() { @@ -20,6 +27,8 @@ class CarbonType extends DateTimeType implements CarbonDoctrineType /** * {@inheritdoc} + * + * @return bool */ public function requiresSQLCommentHint(AbstractPlatform $platform) { diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php index fa0d5b00..ecfe17e7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php @@ -1,9 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. */ + namespace Carbon\Doctrine; use Carbon\Carbon; @@ -26,11 +31,21 @@ trait CarbonTypeConverter return Carbon::class; } + /** + * @return string + */ public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform) { - $precision = ($fieldDeclaration['precision'] ?: 10) === 10 - ? DateTimeDefaultPrecision::get() - : $fieldDeclaration['precision']; + $precision = $fieldDeclaration['precision'] ?: 10; + + if ($fieldDeclaration['secondPrecision'] ?? false) { + $precision = 0; + } + + if ($precision === 10) { + $precision = DateTimeDefaultPrecision::get(); + } + $type = parent::getSQLDeclaration($fieldDeclaration, $platform); if (!$precision) { diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php index f9744b81..642fd413 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php @@ -1,9 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. */ + namespace Carbon\Doctrine; class DateTimeDefaultPrecision diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php index bc2aa797..b3a08719 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php index a9f453eb..d5cd5564 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use BadMethodCallException as BaseBadMethodCallException; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php index 7a28f39c..1d7ec542 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use BadMethodCallException as BaseBadMethodCallException; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php index 307a4ee1..73c2dd86 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; interface BadMethodCallException extends Exception diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php index 86e8a15e..3bbbd77d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; interface Exception diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php index 5fb1c681..a48d4f93 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php index 60ed740d..9739f4d1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; interface InvalidArgumentException extends Exception diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php index 77466c7d..d2f37019 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php index f5dbfe2f..99bb91c0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php index dd26a901..3341b49d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php index b4c76dc8..5f9f142e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php index abe1aef3..a37e3f5e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php index b061ef16..ede47712 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php index 03bd8ac4..892e16e8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php index bc124a65..3fbe3fc4 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php index 78ce9392..2b4c48e3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Carbon\CarbonInterface; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php index 8bdda85b..41bb6290 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php index 8aab1925..adbc36cd 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php index 33cd1b52..54822d95 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php index 3510b409..0314c5d8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php index 6ca5f5f5..24bf5a68 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; interface RuntimeException extends Exception diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php index 838847ba..8bd8653e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php index 7f8ec9eb..39ee12c5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php index 4591d35b..6c8c01b6 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php index 36468724..901db986 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use BadMethodCallException as BaseBadMethodCallException; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php index 5020369a..c9e9c9ff 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php index d2f76eee..d965c82a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php index b38ae12d..6f8b39f5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Exceptions; use Exception; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php index e1d747f2..f8c72890 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php @@ -8,9 +8,11 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Closure; +use DateTimeInterface; use ReflectionMethod; /** @@ -18,208 +20,222 @@ use ReflectionMethod; * * * - * @method bool canBeCreatedFromFormat($date, $format) Checks if the (date)time string is in a given format and valid to create a - * new instance. - * @method Carbon|false create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null) Create a new Carbon instance from a specific date and time. - * If any of $year, $month or $day are set to null their now() values will - * be used. - * If $hour is null it will be set to its now() value and the default - * values for $minute and $second will be their now() values. - * If $hour is not null then the default values for $minute and $second - * will be 0. - * @method Carbon createFromDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to now. - * @method Carbon|false createFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. - * @method Carbon|false createFromIsoFormat($format, $time, $tz = null, $locale = 'en', $translator = null) Create a Carbon instance from a specific ISO format (same replacements as ->isoFormat()). - * @method Carbon|false createFromLocaleFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific format and a string in a given language. - * @method Carbon|false createFromLocaleIsoFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific ISO format and a string in a given language. - * @method Carbon createFromTime($hour = 0, $minute = 0, $second = 0, $tz = null) Create a Carbon instance from just a time. The date portion is set to today. - * @method Carbon createFromTimeString($time, $tz = null) Create a Carbon instance from a time string. The date portion is set to today. - * @method Carbon createFromTimestamp($timestamp, $tz = null) Create a Carbon instance from a timestamp and set the timezone (use default one if not specified). - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method Carbon createFromTimestampMs($timestamp, $tz = null) Create a Carbon instance from a timestamp in milliseconds. - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method Carbon createFromTimestampMsUTC($timestamp) Create a Carbon instance from a timestamp in milliseconds. - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method Carbon createFromTimestampUTC($timestamp) Create a Carbon instance from an timestamp keeping the timezone to UTC. - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method Carbon createMidnightDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to midnight. - * @method Carbon|false createSafe($year = null, $month = null, $day = null, $hour = null, $minute = null, $second = null, $tz = null) Create a new safe Carbon instance from a specific date and time. - * If any of $year, $month or $day are set to null their now() values will - * be used. - * If $hour is null it will be set to its now() value and the default - * values for $minute and $second will be their now() values. - * If $hour is not null then the default values for $minute and $second - * will be 0. - * If one of the set values is not valid, an InvalidDateException - * will be thrown. - * @method CarbonInterface createStrict(?int $year = 0, ?int $month = 1, ?int $day = 1, ?int $hour = 0, ?int $minute = 0, ?int $second = 0, $tz = null) Create a new Carbon instance from a specific date and time using strict validation. - * @method Carbon disableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method Carbon enableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method mixed executeWithLocale($locale, $func) Set the current locale to the given, execute the passed function, reset the locale to previous one, - * then return the result of the closure (or null if the closure was void). - * @method Carbon fromSerialized($value) Create an instance from a serialized string. - * @method void genericMacro($macro, $priority = 0) Register a custom macro. - * @method array getAvailableLocales() Returns the list of internally available locales and already loaded custom locales. - * (It will ignore custom translator dynamic loading.) - * @method Language[] getAvailableLocalesInfo() Returns list of Language object for each available locale. This object allow you to get the ISO name, native - * name, region and variant of the locale. - * @method array getDays() Get the days of the week - * @method string|null getFallbackLocale() Get the fallback locale. - * @method array getFormatsToIsoReplacements() List of replacements from date() format to isoFormat(). - * @method int getHumanDiffOptions() Return default humanDiff() options (merged flags as integer). - * @method array getIsoUnits() Returns list of locale units for ISO formatting. - * @method Carbon getLastErrors() {@inheritdoc} - * @method string getLocale() Get the current translator locale. - * @method callable|null getMacro($name) Get the raw callable macro registered globally for a given name. - * @method int getMidDayAt() get midday/noon hour - * @method Closure|Carbon getTestNow() Get the Carbon instance (real or mock) to be returned when a "now" - * instance is created. - * @method string getTimeFormatByPrecision($unitPrecision) Return a format from H:i to H:i:s.u according to given unit precision. - * @method string getTranslationMessageWith($translator, string $key, ?string $locale = null, ?string $default = null) Returns raw translation message for a given key. - * @method \Symfony\Component\Translation\TranslatorInterface getTranslator() Get the default translator instance in use. - * @method int getWeekEndsAt() Get the last day of week - * @method int getWeekStartsAt() Get the first day of week - * @method array getWeekendDays() Get weekend days - * @method bool hasFormat($date, $format) Checks if the (date)time string is in a given format. - * @method bool hasFormatWithModifiers($date, $format) Checks if the (date)time string is in a given format. - * @method bool hasMacro($name) Checks if macro is registered globally. - * @method bool hasRelativeKeywords($time) Determine if a time string will produce a relative date. - * @method bool hasTestNow() Determine if there is a valid test instance set. A valid test instance - * is anything that is not null. - * @method Carbon instance($date) Create a Carbon instance from a DateTime one. - * @method bool isImmutable() Returns true if the current class/instance is immutable. - * @method bool isModifiableUnit($unit) Returns true if a property can be changed via setter. - * @method bool isMutable() Returns true if the current class/instance is mutable. - * @method bool isStrictModeEnabled() Returns true if the strict mode is globally in use, false else. - * (It can be overridden in specific instances.) - * @method bool localeHasDiffOneDayWords($locale) Returns true if the given locale is internally supported and has words for 1-day diff (just now, yesterday, tomorrow). - * Support is considered enabled if the 3 words are translated in the given locale. - * @method bool localeHasDiffSyntax($locale) Returns true if the given locale is internally supported and has diff syntax support (ago, from now, before, after). - * Support is considered enabled if the 4 sentences are translated in the given locale. - * @method bool localeHasDiffTwoDayWords($locale) Returns true if the given locale is internally supported and has words for 2-days diff (before yesterday, after tomorrow). - * Support is considered enabled if the 2 words are translated in the given locale. - * @method bool localeHasPeriodSyntax($locale) Returns true if the given locale is internally supported and has period syntax support (X times, every X, from X, to X). - * Support is considered enabled if the 4 sentences are translated in the given locale. - * @method bool localeHasShortUnits($locale) Returns true if the given locale is internally supported and has short-units support. - * Support is considered enabled if either year, day or hour has a short variant translated. - * @method void macro($name, $macro) Register a custom macro. - * @method Carbon|null make($var) Make a Carbon instance from given variable if possible. - * Always return a new instance. Parse only strings and only these likely to be dates (skip intervals - * and recurrences). Throw an exception for invalid format, but otherwise return null. - * @method Carbon maxValue() Create a Carbon instance for the greatest supported date. - * @method Carbon minValue() Create a Carbon instance for the lowest supported date. - * @method void mixin($mixin) Mix another object into the class. - * @method Carbon now($tz = null) Get a Carbon instance for the current date and time. - * @method Carbon parse($time = null, $tz = null) Create a carbon instance from a string. - * This is an alias for the constructor that allows better fluent syntax - * as it allows you to do Carbon::parse('Monday next week')->fn() rather - * than (new Carbon('Monday next week'))->fn(). - * @method Carbon parseFromLocale($time, $locale = null, $tz = null) Create a carbon instance from a localized string (in French, Japanese, Arabic, etc.). - * @method string pluralUnit(string $unit) Returns standardized plural of a given singular/plural unit name (in English). - * @method Carbon|false rawCreateFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. - * @method Carbon rawParse($time = null, $tz = null) Create a carbon instance from a string. - * This is an alias for the constructor that allows better fluent syntax - * as it allows you to do Carbon::parse('Monday next week')->fn() rather - * than (new Carbon('Monday next week'))->fn(). - * @method Carbon resetMacros() Remove all macros and generic macros. - * @method void resetMonthsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method void resetToStringFormat() Reset the format used to the default when type juggling a Carbon instance to a string - * @method void resetYearsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method void serializeUsing($callback) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather transform Carbon object before the serialization. - * JSON serialize all Carbon instances using the given callback. - * @method Carbon setFallbackLocale($locale) Set the fallback locale. - * @method Carbon setHumanDiffOptions($humanDiffOptions) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method bool setLocale($locale) Set the current translator locale and indicate if the source locale file exists. - * Pass 'auto' as locale to use closest language from the current LC_TIME locale. - * @method void setMidDayAt($hour) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather consider mid-day is always 12pm, then if you need to test if it's an other - * hour, test it explicitly: - * $date->format('G') == 13 - * or to set explicitly to a given hour: - * $date->setTime(13, 0, 0, 0) - * Set midday/noon hour - * @method Carbon setTestNow($testNow = null) Set a Carbon instance (real or mock) to be returned when a "now" - * instance is created. The provided instance will be returned - * specifically under the following conditions: - * - A call to the static now() method, ex. Carbon::now() - * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) - * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') - * - When a string containing the desired time is passed to Carbon::parse(). - * Note the timezone parameter was left out of the examples above and - * has no affect as the mock value will be returned regardless of its value. - * To clear the test instance call this method using the default - * parameter of null. - * /!\ Use this method for unit tests only. - * @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and - * use other method or custom format passed to format() method if you need to dump an other string - * format. - * Set the default format used when type juggling a Carbon instance to a string - * @method void setTranslator(\Symfony\Component\Translation\TranslatorInterface $translator) Set the default translator instance to use. - * @method Carbon setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use UTF-8 language packages on every machine. - * Set if UTF8 will be used for localized date/time. - * @method void setWeekEndsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * Use $weekStartsAt optional parameter instead when using startOfWeek, floorWeek, ceilWeek - * or roundWeek method. You can also use the 'first_day_of_week' locale setting to change the - * start of week according to current locale selected and implicitly the end of week. - * Set the last day of week - * @method void setWeekStartsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * Use $weekEndsAt optional parameter instead when using endOfWeek method. You can also use the - * 'first_day_of_week' locale setting to change the start of week according to current locale - * selected and implicitly the end of week. - * Set the first day of week - * @method void setWeekendDays($days) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather consider week-end is always saturday and sunday, and if you have some custom - * week-end days to handle, give to those days an other name and create a macro for them: - * ``` - * Carbon::macro('isDayOff', function ($date) { - * return $date->isSunday() || $date->isMonday(); - * }); - * Carbon::macro('isNotDayOff', function ($date) { - * return !$date->isDayOff(); - * }); - * if ($someDate->isDayOff()) ... - * if ($someDate->isNotDayOff()) ... - * // Add 5 not-off days - * $count = 5; - * while ($someDate->isDayOff() || ($count-- > 0)) { - * $someDate->addDay(); - * } - * ``` - * Set weekend days - * @method bool shouldOverflowMonths() Get the month overflow global behavior (can be overridden in specific instances). - * @method bool shouldOverflowYears() Get the month overflow global behavior (can be overridden in specific instances). - * @method string singularUnit(string $unit) Returns standardized singular of a given singular/plural unit name (in English). - * @method Carbon today($tz = null) Create a Carbon instance for today. - * @method Carbon tomorrow($tz = null) Create a Carbon instance for tomorrow. - * @method string translateTimeString($timeString, $from = null, $to = null, $mode = CarbonInterface::TRANSLATE_ALL) Translate a time string from a locale to an other. - * @method string translateWith(\Symfony\Component\Translation\TranslatorInterface $translator, string $key, array $parameters = [], $number = null) Translate using translation string or callback available. - * @method void useMonthsOverflow($monthsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method Carbon useStrictMode($strictModeEnabled = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method void useYearsOverflow($yearsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method mixed withTestNow($testNow = null, $callback = null) Temporarily sets a static date to be used within the callback. - * Using setTestNow to set the date, executing the callback, then - * clearing the test instance. - * /!\ Use this method for unit tests only. - * @method Carbon yesterday($tz = null) Create a Carbon instance for yesterday. + * @method bool canBeCreatedFromFormat($date, $format) Checks if the (date)time string is in a given format and valid to create a + * new instance. + * @method Carbon|false create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null) Create a new Carbon instance from a specific date and time. + * If any of $year, $month or $day are set to null their now() values will + * be used. + * If $hour is null it will be set to its now() value and the default + * values for $minute and $second will be their now() values. + * If $hour is not null then the default values for $minute and $second + * will be 0. + * @method Carbon createFromDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to now. + * @method Carbon|false createFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. + * @method Carbon|false createFromIsoFormat($format, $time, $tz = null, $locale = 'en', $translator = null) Create a Carbon instance from a specific ISO format (same replacements as ->isoFormat()). + * @method Carbon|false createFromLocaleFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific format and a string in a given language. + * @method Carbon|false createFromLocaleIsoFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific ISO format and a string in a given language. + * @method Carbon createFromTime($hour = 0, $minute = 0, $second = 0, $tz = null) Create a Carbon instance from just a time. The date portion is set to today. + * @method Carbon createFromTimeString($time, $tz = null) Create a Carbon instance from a time string. The date portion is set to today. + * @method Carbon createFromTimestamp($timestamp, $tz = null) Create a Carbon instance from a timestamp and set the timezone (use default one if not specified). + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method Carbon createFromTimestampMs($timestamp, $tz = null) Create a Carbon instance from a timestamp in milliseconds. + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method Carbon createFromTimestampMsUTC($timestamp) Create a Carbon instance from a timestamp in milliseconds. + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method Carbon createFromTimestampUTC($timestamp) Create a Carbon instance from an timestamp keeping the timezone to UTC. + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method Carbon createMidnightDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to midnight. + * @method Carbon|false createSafe($year = null, $month = null, $day = null, $hour = null, $minute = null, $second = null, $tz = null) Create a new safe Carbon instance from a specific date and time. + * If any of $year, $month or $day are set to null their now() values will + * be used. + * If $hour is null it will be set to its now() value and the default + * values for $minute and $second will be their now() values. + * If $hour is not null then the default values for $minute and $second + * will be 0. + * If one of the set values is not valid, an InvalidDateException + * will be thrown. + * @method CarbonInterface createStrict(?int $year = 0, ?int $month = 1, ?int $day = 1, ?int $hour = 0, ?int $minute = 0, ?int $second = 0, $tz = null) Create a new Carbon instance from a specific date and time using strict validation. + * @method Carbon disableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method Carbon enableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method mixed executeWithLocale($locale, $func) Set the current locale to the given, execute the passed function, reset the locale to previous one, + * then return the result of the closure (or null if the closure was void). + * @method Carbon fromSerialized($value) Create an instance from a serialized string. + * @method void genericMacro($macro, $priority = 0) Register a custom macro. + * @method array getAvailableLocales() Returns the list of internally available locales and already loaded custom locales. + * (It will ignore custom translator dynamic loading.) + * @method Language[] getAvailableLocalesInfo() Returns list of Language object for each available locale. This object allow you to get the ISO name, native + * name, region and variant of the locale. + * @method array getDays() Get the days of the week + * @method string|null getFallbackLocale() Get the fallback locale. + * @method array getFormatsToIsoReplacements() List of replacements from date() format to isoFormat(). + * @method int getHumanDiffOptions() Return default humanDiff() options (merged flags as integer). + * @method array getIsoUnits() Returns list of locale units for ISO formatting. + * @method array getLastErrors() {@inheritdoc} + * @method string getLocale() Get the current translator locale. + * @method callable|null getMacro($name) Get the raw callable macro registered globally for a given name. + * @method int getMidDayAt() get midday/noon hour + * @method Closure|Carbon getTestNow() Get the Carbon instance (real or mock) to be returned when a "now" + * instance is created. + * @method string getTimeFormatByPrecision($unitPrecision) Return a format from H:i to H:i:s.u according to given unit precision. + * @method string getTranslationMessageWith($translator, string $key, ?string $locale = null, ?string $default = null) Returns raw translation message for a given key. + * @method \Symfony\Component\Translation\TranslatorInterface getTranslator() Get the default translator instance in use. + * @method int getWeekEndsAt() Get the last day of week + * @method int getWeekStartsAt() Get the first day of week + * @method array getWeekendDays() Get weekend days + * @method bool hasFormat($date, $format) Checks if the (date)time string is in a given format. + * @method bool hasFormatWithModifiers($date, $format) Checks if the (date)time string is in a given format. + * @method bool hasMacro($name) Checks if macro is registered globally. + * @method bool hasRelativeKeywords($time) Determine if a time string will produce a relative date. + * @method bool hasTestNow() Determine if there is a valid test instance set. A valid test instance + * is anything that is not null. + * @method Carbon instance($date) Create a Carbon instance from a DateTime one. + * @method bool isImmutable() Returns true if the current class/instance is immutable. + * @method bool isModifiableUnit($unit) Returns true if a property can be changed via setter. + * @method bool isMutable() Returns true if the current class/instance is mutable. + * @method bool isStrictModeEnabled() Returns true if the strict mode is globally in use, false else. + * (It can be overridden in specific instances.) + * @method bool localeHasDiffOneDayWords($locale) Returns true if the given locale is internally supported and has words for 1-day diff (just now, yesterday, tomorrow). + * Support is considered enabled if the 3 words are translated in the given locale. + * @method bool localeHasDiffSyntax($locale) Returns true if the given locale is internally supported and has diff syntax support (ago, from now, before, after). + * Support is considered enabled if the 4 sentences are translated in the given locale. + * @method bool localeHasDiffTwoDayWords($locale) Returns true if the given locale is internally supported and has words for 2-days diff (before yesterday, after tomorrow). + * Support is considered enabled if the 2 words are translated in the given locale. + * @method bool localeHasPeriodSyntax($locale) Returns true if the given locale is internally supported and has period syntax support (X times, every X, from X, to X). + * Support is considered enabled if the 4 sentences are translated in the given locale. + * @method bool localeHasShortUnits($locale) Returns true if the given locale is internally supported and has short-units support. + * Support is considered enabled if either year, day or hour has a short variant translated. + * @method void macro($name, $macro) Register a custom macro. + * @method Carbon|null make($var) Make a Carbon instance from given variable if possible. + * Always return a new instance. Parse only strings and only these likely to be dates (skip intervals + * and recurrences). Throw an exception for invalid format, but otherwise return null. + * @method Carbon maxValue() Create a Carbon instance for the greatest supported date. + * @method Carbon minValue() Create a Carbon instance for the lowest supported date. + * @method void mixin($mixin) Mix another object into the class. + * @method Carbon now($tz = null) Get a Carbon instance for the current date and time. + * @method Carbon parse($time = null, $tz = null) Create a carbon instance from a string. + * This is an alias for the constructor that allows better fluent syntax + * as it allows you to do Carbon::parse('Monday next week')->fn() rather + * than (new Carbon('Monday next week'))->fn(). + * @method Carbon parseFromLocale($time, $locale = null, $tz = null) Create a carbon instance from a localized string (in French, Japanese, Arabic, etc.). + * @method string pluralUnit(string $unit) Returns standardized plural of a given singular/plural unit name (in English). + * @method Carbon|false rawCreateFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. + * @method Carbon rawParse($time = null, $tz = null) Create a carbon instance from a string. + * This is an alias for the constructor that allows better fluent syntax + * as it allows you to do Carbon::parse('Monday next week')->fn() rather + * than (new Carbon('Monday next week'))->fn(). + * @method Carbon resetMacros() Remove all macros and generic macros. + * @method void resetMonthsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method void resetToStringFormat() Reset the format used to the default when type juggling a Carbon instance to a string + * @method void resetYearsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method void serializeUsing($callback) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather transform Carbon object before the serialization. + * JSON serialize all Carbon instances using the given callback. + * @method Carbon setFallbackLocale($locale) Set the fallback locale. + * @method Carbon setHumanDiffOptions($humanDiffOptions) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method bool setLocale($locale) Set the current translator locale and indicate if the source locale file exists. + * Pass 'auto' as locale to use closest language from the current LC_TIME locale. + * @method void setMidDayAt($hour) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather consider mid-day is always 12pm, then if you need to test if it's an other + * hour, test it explicitly: + * $date->format('G') == 13 + * or to set explicitly to a given hour: + * $date->setTime(13, 0, 0, 0) + * Set midday/noon hour + * @method Carbon setTestNow($testNow = null) Set a Carbon instance (real or mock) to be returned when a "now" + * instance is created. The provided instance will be returned + * specifically under the following conditions: + * - A call to the static now() method, ex. Carbon::now() + * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) + * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') + * - When a string containing the desired time is passed to Carbon::parse(). + * Note the timezone parameter was left out of the examples above and + * has no affect as the mock value will be returned regardless of its value. + * Only the moment is mocked with setTestNow(), the timezone will still be the one passed + * as parameter of date_default_timezone_get() as a fallback (see setTestNowAndTimezone()). + * To clear the test instance call this method using the default + * parameter of null. + * /!\ Use this method for unit tests only. + * @method Carbon setTestNowAndTimezone($testNow = null, $tz = null) Set a Carbon instance (real or mock) to be returned when a "now" + * instance is created. The provided instance will be returned + * specifically under the following conditions: + * - A call to the static now() method, ex. Carbon::now() + * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) + * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') + * - When a string containing the desired time is passed to Carbon::parse(). + * It will also align default timezone (e.g. call date_default_timezone_set()) with + * the second argument or if null, with the timezone of the given date object. + * To clear the test instance call this method using the default + * parameter of null. + * /!\ Use this method for unit tests only. + * @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and + * use other method or custom format passed to format() method if you need to dump an other string + * format. + * Set the default format used when type juggling a Carbon instance to a string + * @method void setTranslator(TranslatorInterface $translator) Set the default translator instance to use. + * @method Carbon setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use UTF-8 language packages on every machine. + * Set if UTF8 will be used for localized date/time. + * @method void setWeekEndsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * Use $weekStartsAt optional parameter instead when using startOfWeek, floorWeek, ceilWeek + * or roundWeek method. You can also use the 'first_day_of_week' locale setting to change the + * start of week according to current locale selected and implicitly the end of week. + * Set the last day of week + * @method void setWeekStartsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * Use $weekEndsAt optional parameter instead when using endOfWeek method. You can also use the + * 'first_day_of_week' locale setting to change the start of week according to current locale + * selected and implicitly the end of week. + * Set the first day of week + * @method void setWeekendDays($days) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather consider week-end is always saturday and sunday, and if you have some custom + * week-end days to handle, give to those days an other name and create a macro for them: + * ``` + * Carbon::macro('isDayOff', function ($date) { + * return $date->isSunday() || $date->isMonday(); + * }); + * Carbon::macro('isNotDayOff', function ($date) { + * return !$date->isDayOff(); + * }); + * if ($someDate->isDayOff()) ... + * if ($someDate->isNotDayOff()) ... + * // Add 5 not-off days + * $count = 5; + * while ($someDate->isDayOff() || ($count-- > 0)) { + * $someDate->addDay(); + * } + * ``` + * Set weekend days + * @method bool shouldOverflowMonths() Get the month overflow global behavior (can be overridden in specific instances). + * @method bool shouldOverflowYears() Get the month overflow global behavior (can be overridden in specific instances). + * @method string singularUnit(string $unit) Returns standardized singular of a given singular/plural unit name (in English). + * @method Carbon today($tz = null) Create a Carbon instance for today. + * @method Carbon tomorrow($tz = null) Create a Carbon instance for tomorrow. + * @method string translateTimeString($timeString, $from = null, $to = null, $mode = CarbonInterface::TRANSLATE_ALL) Translate a time string from a locale to an other. + * @method string translateWith(TranslatorInterface $translator, string $key, array $parameters = [], $number = null) Translate using translation string or callback available. + * @method void useMonthsOverflow($monthsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method Carbon useStrictMode($strictModeEnabled = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method void useYearsOverflow($yearsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method mixed withTestNow($testNow = null, $callback = null) Temporarily sets a static date to be used within the callback. + * Using setTestNow to set the date, executing the callback, then + * clearing the test instance. + * /!\ Use this method for unit tests only. + * @method Carbon yesterday($tz = null) Create a Carbon instance for yesterday. * * */ @@ -289,7 +305,13 @@ class Factory return \in_array($parameter->getName(), ['tz', 'timezone'], true); }); - if (\count($tzParameters)) { + if (isset($arguments[0]) && \in_array($name, ['instance', 'make', 'create', 'parse'], true)) { + if ($arguments[0] instanceof DateTimeInterface) { + $settings['innerTimezone'] = $settings['timezone']; + } elseif (\is_string($arguments[0]) && date_parse($arguments[0])['is_localtime']) { + unset($settings['timezone'], $settings['innerTimezone']); + } + } elseif (\count($tzParameters)) { array_splice($arguments, key($tzParameters), 0, [$settings['timezone']]); unset($settings['timezone']); } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php index 3aa286c0..596ee806 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use Closure; @@ -17,208 +18,222 @@ use Closure; * * * - * @method bool canBeCreatedFromFormat($date, $format) Checks if the (date)time string is in a given format and valid to create a - * new instance. - * @method CarbonImmutable|false create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null) Create a new Carbon instance from a specific date and time. - * If any of $year, $month or $day are set to null their now() values will - * be used. - * If $hour is null it will be set to its now() value and the default - * values for $minute and $second will be their now() values. - * If $hour is not null then the default values for $minute and $second - * will be 0. - * @method CarbonImmutable createFromDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to now. - * @method CarbonImmutable|false createFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. - * @method CarbonImmutable|false createFromIsoFormat($format, $time, $tz = null, $locale = 'en', $translator = null) Create a Carbon instance from a specific ISO format (same replacements as ->isoFormat()). - * @method CarbonImmutable|false createFromLocaleFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific format and a string in a given language. - * @method CarbonImmutable|false createFromLocaleIsoFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific ISO format and a string in a given language. - * @method CarbonImmutable createFromTime($hour = 0, $minute = 0, $second = 0, $tz = null) Create a Carbon instance from just a time. The date portion is set to today. - * @method CarbonImmutable createFromTimeString($time, $tz = null) Create a Carbon instance from a time string. The date portion is set to today. - * @method CarbonImmutable createFromTimestamp($timestamp, $tz = null) Create a Carbon instance from a timestamp and set the timezone (use default one if not specified). - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method CarbonImmutable createFromTimestampMs($timestamp, $tz = null) Create a Carbon instance from a timestamp in milliseconds. - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method CarbonImmutable createFromTimestampMsUTC($timestamp) Create a Carbon instance from a timestamp in milliseconds. - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method CarbonImmutable createFromTimestampUTC($timestamp) Create a Carbon instance from an timestamp keeping the timezone to UTC. - * Timestamp input can be given as int, float or a string containing one or more numbers. - * @method CarbonImmutable createMidnightDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to midnight. - * @method CarbonImmutable|false createSafe($year = null, $month = null, $day = null, $hour = null, $minute = null, $second = null, $tz = null) Create a new safe Carbon instance from a specific date and time. - * If any of $year, $month or $day are set to null their now() values will - * be used. - * If $hour is null it will be set to its now() value and the default - * values for $minute and $second will be their now() values. - * If $hour is not null then the default values for $minute and $second - * will be 0. - * If one of the set values is not valid, an InvalidDateException - * will be thrown. - * @method CarbonInterface createStrict(?int $year = 0, ?int $month = 1, ?int $day = 1, ?int $hour = 0, ?int $minute = 0, ?int $second = 0, $tz = null) Create a new Carbon instance from a specific date and time using strict validation. - * @method CarbonImmutable disableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method CarbonImmutable enableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method mixed executeWithLocale($locale, $func) Set the current locale to the given, execute the passed function, reset the locale to previous one, - * then return the result of the closure (or null if the closure was void). - * @method CarbonImmutable fromSerialized($value) Create an instance from a serialized string. - * @method void genericMacro($macro, $priority = 0) Register a custom macro. - * @method array getAvailableLocales() Returns the list of internally available locales and already loaded custom locales. - * (It will ignore custom translator dynamic loading.) - * @method Language[] getAvailableLocalesInfo() Returns list of Language object for each available locale. This object allow you to get the ISO name, native - * name, region and variant of the locale. - * @method array getDays() Get the days of the week - * @method string|null getFallbackLocale() Get the fallback locale. - * @method array getFormatsToIsoReplacements() List of replacements from date() format to isoFormat(). - * @method int getHumanDiffOptions() Return default humanDiff() options (merged flags as integer). - * @method array getIsoUnits() Returns list of locale units for ISO formatting. - * @method CarbonImmutable getLastErrors() {@inheritdoc} - * @method string getLocale() Get the current translator locale. - * @method callable|null getMacro($name) Get the raw callable macro registered globally for a given name. - * @method int getMidDayAt() get midday/noon hour - * @method Closure|CarbonImmutable getTestNow() Get the Carbon instance (real or mock) to be returned when a "now" - * instance is created. - * @method string getTimeFormatByPrecision($unitPrecision) Return a format from H:i to H:i:s.u according to given unit precision. - * @method string getTranslationMessageWith($translator, string $key, ?string $locale = null, ?string $default = null) Returns raw translation message for a given key. - * @method \Symfony\Component\Translation\TranslatorInterface getTranslator() Get the default translator instance in use. - * @method int getWeekEndsAt() Get the last day of week - * @method int getWeekStartsAt() Get the first day of week - * @method array getWeekendDays() Get weekend days - * @method bool hasFormat($date, $format) Checks if the (date)time string is in a given format. - * @method bool hasFormatWithModifiers($date, $format) Checks if the (date)time string is in a given format. - * @method bool hasMacro($name) Checks if macro is registered globally. - * @method bool hasRelativeKeywords($time) Determine if a time string will produce a relative date. - * @method bool hasTestNow() Determine if there is a valid test instance set. A valid test instance - * is anything that is not null. - * @method CarbonImmutable instance($date) Create a Carbon instance from a DateTime one. - * @method bool isImmutable() Returns true if the current class/instance is immutable. - * @method bool isModifiableUnit($unit) Returns true if a property can be changed via setter. - * @method bool isMutable() Returns true if the current class/instance is mutable. - * @method bool isStrictModeEnabled() Returns true if the strict mode is globally in use, false else. - * (It can be overridden in specific instances.) - * @method bool localeHasDiffOneDayWords($locale) Returns true if the given locale is internally supported and has words for 1-day diff (just now, yesterday, tomorrow). - * Support is considered enabled if the 3 words are translated in the given locale. - * @method bool localeHasDiffSyntax($locale) Returns true if the given locale is internally supported and has diff syntax support (ago, from now, before, after). - * Support is considered enabled if the 4 sentences are translated in the given locale. - * @method bool localeHasDiffTwoDayWords($locale) Returns true if the given locale is internally supported and has words for 2-days diff (before yesterday, after tomorrow). - * Support is considered enabled if the 2 words are translated in the given locale. - * @method bool localeHasPeriodSyntax($locale) Returns true if the given locale is internally supported and has period syntax support (X times, every X, from X, to X). - * Support is considered enabled if the 4 sentences are translated in the given locale. - * @method bool localeHasShortUnits($locale) Returns true if the given locale is internally supported and has short-units support. - * Support is considered enabled if either year, day or hour has a short variant translated. - * @method void macro($name, $macro) Register a custom macro. - * @method CarbonImmutable|null make($var) Make a Carbon instance from given variable if possible. - * Always return a new instance. Parse only strings and only these likely to be dates (skip intervals - * and recurrences). Throw an exception for invalid format, but otherwise return null. - * @method CarbonImmutable maxValue() Create a Carbon instance for the greatest supported date. - * @method CarbonImmutable minValue() Create a Carbon instance for the lowest supported date. - * @method void mixin($mixin) Mix another object into the class. - * @method CarbonImmutable now($tz = null) Get a Carbon instance for the current date and time. - * @method CarbonImmutable parse($time = null, $tz = null) Create a carbon instance from a string. - * This is an alias for the constructor that allows better fluent syntax - * as it allows you to do Carbon::parse('Monday next week')->fn() rather - * than (new Carbon('Monday next week'))->fn(). - * @method CarbonImmutable parseFromLocale($time, $locale = null, $tz = null) Create a carbon instance from a localized string (in French, Japanese, Arabic, etc.). - * @method string pluralUnit(string $unit) Returns standardized plural of a given singular/plural unit name (in English). - * @method CarbonImmutable|false rawCreateFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. - * @method CarbonImmutable rawParse($time = null, $tz = null) Create a carbon instance from a string. - * This is an alias for the constructor that allows better fluent syntax - * as it allows you to do Carbon::parse('Monday next week')->fn() rather - * than (new Carbon('Monday next week'))->fn(). - * @method CarbonImmutable resetMacros() Remove all macros and generic macros. - * @method void resetMonthsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method void resetToStringFormat() Reset the format used to the default when type juggling a Carbon instance to a string - * @method void resetYearsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method void serializeUsing($callback) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather transform Carbon object before the serialization. - * JSON serialize all Carbon instances using the given callback. - * @method CarbonImmutable setFallbackLocale($locale) Set the fallback locale. - * @method CarbonImmutable setHumanDiffOptions($humanDiffOptions) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method bool setLocale($locale) Set the current translator locale and indicate if the source locale file exists. - * Pass 'auto' as locale to use closest language from the current LC_TIME locale. - * @method void setMidDayAt($hour) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather consider mid-day is always 12pm, then if you need to test if it's an other - * hour, test it explicitly: - * $date->format('G') == 13 - * or to set explicitly to a given hour: - * $date->setTime(13, 0, 0, 0) - * Set midday/noon hour - * @method CarbonImmutable setTestNow($testNow = null) Set a Carbon instance (real or mock) to be returned when a "now" - * instance is created. The provided instance will be returned - * specifically under the following conditions: - * - A call to the static now() method, ex. Carbon::now() - * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) - * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') - * - When a string containing the desired time is passed to Carbon::parse(). - * Note the timezone parameter was left out of the examples above and - * has no affect as the mock value will be returned regardless of its value. - * To clear the test instance call this method using the default - * parameter of null. - * /!\ Use this method for unit tests only. - * @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and - * use other method or custom format passed to format() method if you need to dump an other string - * format. - * Set the default format used when type juggling a Carbon instance to a string - * @method void setTranslator(\Symfony\Component\Translation\TranslatorInterface $translator) Set the default translator instance to use. - * @method CarbonImmutable setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use UTF-8 language packages on every machine. - * Set if UTF8 will be used for localized date/time. - * @method void setWeekEndsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * Use $weekStartsAt optional parameter instead when using startOfWeek, floorWeek, ceilWeek - * or roundWeek method. You can also use the 'first_day_of_week' locale setting to change the - * start of week according to current locale selected and implicitly the end of week. - * Set the last day of week - * @method void setWeekStartsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * Use $weekEndsAt optional parameter instead when using endOfWeek method. You can also use the - * 'first_day_of_week' locale setting to change the start of week according to current locale - * selected and implicitly the end of week. - * Set the first day of week - * @method void setWeekendDays($days) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather consider week-end is always saturday and sunday, and if you have some custom - * week-end days to handle, give to those days an other name and create a macro for them: - * ``` - * Carbon::macro('isDayOff', function ($date) { - * return $date->isSunday() || $date->isMonday(); - * }); - * Carbon::macro('isNotDayOff', function ($date) { - * return !$date->isDayOff(); - * }); - * if ($someDate->isDayOff()) ... - * if ($someDate->isNotDayOff()) ... - * // Add 5 not-off days - * $count = 5; - * while ($someDate->isDayOff() || ($count-- > 0)) { - * $someDate->addDay(); - * } - * ``` - * Set weekend days - * @method bool shouldOverflowMonths() Get the month overflow global behavior (can be overridden in specific instances). - * @method bool shouldOverflowYears() Get the month overflow global behavior (can be overridden in specific instances). - * @method string singularUnit(string $unit) Returns standardized singular of a given singular/plural unit name (in English). - * @method CarbonImmutable today($tz = null) Create a Carbon instance for today. - * @method CarbonImmutable tomorrow($tz = null) Create a Carbon instance for tomorrow. - * @method string translateTimeString($timeString, $from = null, $to = null, $mode = CarbonInterface::TRANSLATE_ALL) Translate a time string from a locale to an other. - * @method string translateWith(\Symfony\Component\Translation\TranslatorInterface $translator, string $key, array $parameters = [], $number = null) Translate using translation string or callback available. - * @method void useMonthsOverflow($monthsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method CarbonImmutable useStrictMode($strictModeEnabled = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * @method void useYearsOverflow($yearsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. - * You should rather use the ->settings() method. - * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants - * are available for quarters, years, decade, centuries, millennia (singular and plural forms). - * @method mixed withTestNow($testNow = null, $callback = null) Temporarily sets a static date to be used within the callback. - * Using setTestNow to set the date, executing the callback, then - * clearing the test instance. - * /!\ Use this method for unit tests only. - * @method CarbonImmutable yesterday($tz = null) Create a Carbon instance for yesterday. + * @method bool canBeCreatedFromFormat($date, $format) Checks if the (date)time string is in a given format and valid to create a + * new instance. + * @method CarbonImmutable|false create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null) Create a new Carbon instance from a specific date and time. + * If any of $year, $month or $day are set to null their now() values will + * be used. + * If $hour is null it will be set to its now() value and the default + * values for $minute and $second will be their now() values. + * If $hour is not null then the default values for $minute and $second + * will be 0. + * @method CarbonImmutable createFromDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to now. + * @method CarbonImmutable|false createFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. + * @method CarbonImmutable|false createFromIsoFormat($format, $time, $tz = null, $locale = 'en', $translator = null) Create a Carbon instance from a specific ISO format (same replacements as ->isoFormat()). + * @method CarbonImmutable|false createFromLocaleFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific format and a string in a given language. + * @method CarbonImmutable|false createFromLocaleIsoFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific ISO format and a string in a given language. + * @method CarbonImmutable createFromTime($hour = 0, $minute = 0, $second = 0, $tz = null) Create a Carbon instance from just a time. The date portion is set to today. + * @method CarbonImmutable createFromTimeString($time, $tz = null) Create a Carbon instance from a time string. The date portion is set to today. + * @method CarbonImmutable createFromTimestamp($timestamp, $tz = null) Create a Carbon instance from a timestamp and set the timezone (use default one if not specified). + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method CarbonImmutable createFromTimestampMs($timestamp, $tz = null) Create a Carbon instance from a timestamp in milliseconds. + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method CarbonImmutable createFromTimestampMsUTC($timestamp) Create a Carbon instance from a timestamp in milliseconds. + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method CarbonImmutable createFromTimestampUTC($timestamp) Create a Carbon instance from an timestamp keeping the timezone to UTC. + * Timestamp input can be given as int, float or a string containing one or more numbers. + * @method CarbonImmutable createMidnightDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to midnight. + * @method CarbonImmutable|false createSafe($year = null, $month = null, $day = null, $hour = null, $minute = null, $second = null, $tz = null) Create a new safe Carbon instance from a specific date and time. + * If any of $year, $month or $day are set to null their now() values will + * be used. + * If $hour is null it will be set to its now() value and the default + * values for $minute and $second will be their now() values. + * If $hour is not null then the default values for $minute and $second + * will be 0. + * If one of the set values is not valid, an InvalidDateException + * will be thrown. + * @method CarbonInterface createStrict(?int $year = 0, ?int $month = 1, ?int $day = 1, ?int $hour = 0, ?int $minute = 0, ?int $second = 0, $tz = null) Create a new Carbon instance from a specific date and time using strict validation. + * @method CarbonImmutable disableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method CarbonImmutable enableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method mixed executeWithLocale($locale, $func) Set the current locale to the given, execute the passed function, reset the locale to previous one, + * then return the result of the closure (or null if the closure was void). + * @method CarbonImmutable fromSerialized($value) Create an instance from a serialized string. + * @method void genericMacro($macro, $priority = 0) Register a custom macro. + * @method array getAvailableLocales() Returns the list of internally available locales and already loaded custom locales. + * (It will ignore custom translator dynamic loading.) + * @method Language[] getAvailableLocalesInfo() Returns list of Language object for each available locale. This object allow you to get the ISO name, native + * name, region and variant of the locale. + * @method array getDays() Get the days of the week + * @method string|null getFallbackLocale() Get the fallback locale. + * @method array getFormatsToIsoReplacements() List of replacements from date() format to isoFormat(). + * @method int getHumanDiffOptions() Return default humanDiff() options (merged flags as integer). + * @method array getIsoUnits() Returns list of locale units for ISO formatting. + * @method array getLastErrors() {@inheritdoc} + * @method string getLocale() Get the current translator locale. + * @method callable|null getMacro($name) Get the raw callable macro registered globally for a given name. + * @method int getMidDayAt() get midday/noon hour + * @method Closure|CarbonImmutable getTestNow() Get the Carbon instance (real or mock) to be returned when a "now" + * instance is created. + * @method string getTimeFormatByPrecision($unitPrecision) Return a format from H:i to H:i:s.u according to given unit precision. + * @method string getTranslationMessageWith($translator, string $key, ?string $locale = null, ?string $default = null) Returns raw translation message for a given key. + * @method \Symfony\Component\Translation\TranslatorInterface getTranslator() Get the default translator instance in use. + * @method int getWeekEndsAt() Get the last day of week + * @method int getWeekStartsAt() Get the first day of week + * @method array getWeekendDays() Get weekend days + * @method bool hasFormat($date, $format) Checks if the (date)time string is in a given format. + * @method bool hasFormatWithModifiers($date, $format) Checks if the (date)time string is in a given format. + * @method bool hasMacro($name) Checks if macro is registered globally. + * @method bool hasRelativeKeywords($time) Determine if a time string will produce a relative date. + * @method bool hasTestNow() Determine if there is a valid test instance set. A valid test instance + * is anything that is not null. + * @method CarbonImmutable instance($date) Create a Carbon instance from a DateTime one. + * @method bool isImmutable() Returns true if the current class/instance is immutable. + * @method bool isModifiableUnit($unit) Returns true if a property can be changed via setter. + * @method bool isMutable() Returns true if the current class/instance is mutable. + * @method bool isStrictModeEnabled() Returns true if the strict mode is globally in use, false else. + * (It can be overridden in specific instances.) + * @method bool localeHasDiffOneDayWords($locale) Returns true if the given locale is internally supported and has words for 1-day diff (just now, yesterday, tomorrow). + * Support is considered enabled if the 3 words are translated in the given locale. + * @method bool localeHasDiffSyntax($locale) Returns true if the given locale is internally supported and has diff syntax support (ago, from now, before, after). + * Support is considered enabled if the 4 sentences are translated in the given locale. + * @method bool localeHasDiffTwoDayWords($locale) Returns true if the given locale is internally supported and has words for 2-days diff (before yesterday, after tomorrow). + * Support is considered enabled if the 2 words are translated in the given locale. + * @method bool localeHasPeriodSyntax($locale) Returns true if the given locale is internally supported and has period syntax support (X times, every X, from X, to X). + * Support is considered enabled if the 4 sentences are translated in the given locale. + * @method bool localeHasShortUnits($locale) Returns true if the given locale is internally supported and has short-units support. + * Support is considered enabled if either year, day or hour has a short variant translated. + * @method void macro($name, $macro) Register a custom macro. + * @method CarbonImmutable|null make($var) Make a Carbon instance from given variable if possible. + * Always return a new instance. Parse only strings and only these likely to be dates (skip intervals + * and recurrences). Throw an exception for invalid format, but otherwise return null. + * @method CarbonImmutable maxValue() Create a Carbon instance for the greatest supported date. + * @method CarbonImmutable minValue() Create a Carbon instance for the lowest supported date. + * @method void mixin($mixin) Mix another object into the class. + * @method CarbonImmutable now($tz = null) Get a Carbon instance for the current date and time. + * @method CarbonImmutable parse($time = null, $tz = null) Create a carbon instance from a string. + * This is an alias for the constructor that allows better fluent syntax + * as it allows you to do Carbon::parse('Monday next week')->fn() rather + * than (new Carbon('Monday next week'))->fn(). + * @method CarbonImmutable parseFromLocale($time, $locale = null, $tz = null) Create a carbon instance from a localized string (in French, Japanese, Arabic, etc.). + * @method string pluralUnit(string $unit) Returns standardized plural of a given singular/plural unit name (in English). + * @method CarbonImmutable|false rawCreateFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format. + * @method CarbonImmutable rawParse($time = null, $tz = null) Create a carbon instance from a string. + * This is an alias for the constructor that allows better fluent syntax + * as it allows you to do Carbon::parse('Monday next week')->fn() rather + * than (new Carbon('Monday next week'))->fn(). + * @method CarbonImmutable resetMacros() Remove all macros and generic macros. + * @method void resetMonthsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method void resetToStringFormat() Reset the format used to the default when type juggling a Carbon instance to a string + * @method void resetYearsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method void serializeUsing($callback) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather transform Carbon object before the serialization. + * JSON serialize all Carbon instances using the given callback. + * @method CarbonImmutable setFallbackLocale($locale) Set the fallback locale. + * @method CarbonImmutable setHumanDiffOptions($humanDiffOptions) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method bool setLocale($locale) Set the current translator locale and indicate if the source locale file exists. + * Pass 'auto' as locale to use closest language from the current LC_TIME locale. + * @method void setMidDayAt($hour) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather consider mid-day is always 12pm, then if you need to test if it's an other + * hour, test it explicitly: + * $date->format('G') == 13 + * or to set explicitly to a given hour: + * $date->setTime(13, 0, 0, 0) + * Set midday/noon hour + * @method CarbonImmutable setTestNow($testNow = null) Set a Carbon instance (real or mock) to be returned when a "now" + * instance is created. The provided instance will be returned + * specifically under the following conditions: + * - A call to the static now() method, ex. Carbon::now() + * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) + * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') + * - When a string containing the desired time is passed to Carbon::parse(). + * Note the timezone parameter was left out of the examples above and + * has no affect as the mock value will be returned regardless of its value. + * Only the moment is mocked with setTestNow(), the timezone will still be the one passed + * as parameter of date_default_timezone_get() as a fallback (see setTestNowAndTimezone()). + * To clear the test instance call this method using the default + * parameter of null. + * /!\ Use this method for unit tests only. + * @method CarbonImmutable setTestNowAndTimezone($testNow = null, $tz = null) Set a Carbon instance (real or mock) to be returned when a "now" + * instance is created. The provided instance will be returned + * specifically under the following conditions: + * - A call to the static now() method, ex. Carbon::now() + * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) + * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') + * - When a string containing the desired time is passed to Carbon::parse(). + * It will also align default timezone (e.g. call date_default_timezone_set()) with + * the second argument or if null, with the timezone of the given date object. + * To clear the test instance call this method using the default + * parameter of null. + * /!\ Use this method for unit tests only. + * @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and + * use other method or custom format passed to format() method if you need to dump an other string + * format. + * Set the default format used when type juggling a Carbon instance to a string + * @method void setTranslator(TranslatorInterface $translator) Set the default translator instance to use. + * @method CarbonImmutable setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use UTF-8 language packages on every machine. + * Set if UTF8 will be used for localized date/time. + * @method void setWeekEndsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * Use $weekStartsAt optional parameter instead when using startOfWeek, floorWeek, ceilWeek + * or roundWeek method. You can also use the 'first_day_of_week' locale setting to change the + * start of week according to current locale selected and implicitly the end of week. + * Set the last day of week + * @method void setWeekStartsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * Use $weekEndsAt optional parameter instead when using endOfWeek method. You can also use the + * 'first_day_of_week' locale setting to change the start of week according to current locale + * selected and implicitly the end of week. + * Set the first day of week + * @method void setWeekendDays($days) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather consider week-end is always saturday and sunday, and if you have some custom + * week-end days to handle, give to those days an other name and create a macro for them: + * ``` + * Carbon::macro('isDayOff', function ($date) { + * return $date->isSunday() || $date->isMonday(); + * }); + * Carbon::macro('isNotDayOff', function ($date) { + * return !$date->isDayOff(); + * }); + * if ($someDate->isDayOff()) ... + * if ($someDate->isNotDayOff()) ... + * // Add 5 not-off days + * $count = 5; + * while ($someDate->isDayOff() || ($count-- > 0)) { + * $someDate->addDay(); + * } + * ``` + * Set weekend days + * @method bool shouldOverflowMonths() Get the month overflow global behavior (can be overridden in specific instances). + * @method bool shouldOverflowYears() Get the month overflow global behavior (can be overridden in specific instances). + * @method string singularUnit(string $unit) Returns standardized singular of a given singular/plural unit name (in English). + * @method CarbonImmutable today($tz = null) Create a Carbon instance for today. + * @method CarbonImmutable tomorrow($tz = null) Create a Carbon instance for tomorrow. + * @method string translateTimeString($timeString, $from = null, $to = null, $mode = CarbonInterface::TRANSLATE_ALL) Translate a time string from a locale to an other. + * @method string translateWith(TranslatorInterface $translator, string $key, array $parameters = [], $number = null) Translate using translation string or callback available. + * @method void useMonthsOverflow($monthsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method CarbonImmutable useStrictMode($strictModeEnabled = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * @method void useYearsOverflow($yearsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used. + * You should rather use the ->settings() method. + * Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants + * are available for quarters, years, decade, centuries, millennia (singular and plural forms). + * @method mixed withTestNow($testNow = null, $callback = null) Temporarily sets a static date to be used within the callback. + * Using setTestNow to set the date, executing the callback, then + * clearing the test instance. + * /!\ Use this method for unit tests only. + * @method CarbonImmutable yesterday($tz = null) Create a Carbon instance for yesterday. * * */ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_NA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_NA.php index 40d8d86c..f2fcf053 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_NA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_NA.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/af.php', [ 'meridiem' => ['v', 'n'], 'weekdays' => ['Sondag', 'Maandag', 'Dinsdag', 'Woensdag', 'Donderdag', 'Vrydag', 'Saterdag'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_ZA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_ZA.php index 93f4c839..27896bd0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_ZA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/af_ZA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/af.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/agq.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/agq.php index 58c7a110..70114649 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/agq.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/agq.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['a.g', 'a.k'], 'weekdays' => ['tsuʔntsɨ', 'tsuʔukpà', 'tsuʔughɔe', 'tsuʔutɔ̀mlò', 'tsuʔumè', 'tsuʔughɨ̂m', 'tsuʔndzɨkɔʔɔ'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_DJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_DJ.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_DJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_DJ.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EH.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EH.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_ER.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_ER.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_ER.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_ER.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IL.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IL.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KM.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KM.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_MR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_MR.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_MR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_MR.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SO.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SO.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_TD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_TD.php index 8d377adb..e790b99e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_TD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_TD.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ar.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/asa.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/asa.php index 83897571..03bb4839 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/asa.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/asa.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['icheheavo', 'ichamthi'], 'weekdays' => ['Jumapili', 'Jumatatu', 'Jumanne', 'Jumatano', 'Alhamisi', 'Ijumaa', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Cyrl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Cyrl.php index d6979180..28fc62fe 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Cyrl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Cyrl.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/az.php', [ 'weekdays' => ['базар', 'базар ертәси', 'чәршәнбә ахшамы', 'чәршәнбә', 'ҹүмә ахшамы', 'ҹүмә', 'шәнбә'], 'weekdays_short' => ['Б.', 'Б.Е.', 'Ч.А.', 'Ч.', 'Ҹ.А.', 'Ҹ.', 'Ш.'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Latn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Latn.php index 8346a5dd..0be33914 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Latn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/az_Latn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/az.php', [ 'meridiem' => ['a', 'p'], 'weekdays' => ['bazar', 'bazar ertəsi', 'çərşənbə axşamı', 'çərşənbə', 'cümə axşamı', 'cümə', 'şənbə'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bas.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bas.php index 1b342bbc..41bfa1d8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bas.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bas.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['I bikɛ̂glà', 'I ɓugajɔp'], 'weekdays' => ['ŋgwà nɔ̂y', 'ŋgwà njaŋgumba', 'ŋgwà ûm', 'ŋgwà ŋgê', 'ŋgwà mbɔk', 'ŋgwà kɔɔ', 'ŋgwà jôn'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php index ce8dbe83..51b4d0cc 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php @@ -8,9 +8,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + // @codeCoverageIgnoreStart + +use Carbon\CarbonInterface; +use Symfony\Component\Translation\PluralizationRules; + if (class_exists('Symfony\\Component\\Translation\\PluralizationRules')) { - \Symfony\Component\Translation\PluralizationRules::set(function ($number) { + PluralizationRules::set(function ($number) { return (($number % 10 == 1) && ($number % 100 != 11)) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2); }, 'be'); } @@ -113,7 +118,7 @@ return [ 'nextDay' => '[Заўтра ў] LT', 'nextWeek' => '[У] dddd [ў] LT', 'lastDay' => '[Учора ў] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { switch ($current->dayOfWeek) { case 1: case 2: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bez.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bez.php index 1facc9dc..d59c5ef5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bez.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bez.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['pamilau', 'pamunyi'], 'weekdays' => ['pa mulungu', 'pa shahuviluha', 'pa hivili', 'pa hidatu', 'pa hitayi', 'pa hihanu', 'pa shahulembela'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg.php index 0e17673e..f7680740 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg.php @@ -17,6 +17,9 @@ * - JD Isaacks * - Glavić */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count година|:count години', 'a_year' => 'година|:count години', @@ -63,7 +66,7 @@ return [ 'nextDay' => '[Утре в] LT', 'nextWeek' => 'dddd [в] LT', 'lastDay' => '[Вчера в] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { switch ($current->dayOfWeek) { case 0: case 3: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg_BG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg_BG.php index 85c0783e..b53874d3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg_BG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bg_BG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/bg.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_CN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_CN.php index c3d9d8b1..380abb1e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_CN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_CN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/bo.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_IN.php index a377fb54..ca50d049 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bo_IN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/bo.php', [ 'meridiem' => ['སྔ་དྲོ་', 'ཕྱི་དྲོ་'], 'weekdays' => ['གཟའ་ཉི་མ་', 'གཟའ་ཟླ་བ་', 'གཟའ་མིག་དམར་', 'གཟའ་ལྷག་པ་', 'གཟའ་ཕུར་བུ་', 'གཟའ་པ་སངས་', 'གཟའ་སྤེན་པ་'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/br_FR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/br_FR.php index 9d939fd9..7f541858 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/br_FR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/br_FR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/br.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs.php index d2fc5aaa..e5d68083 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs.php @@ -18,6 +18,9 @@ * - Serhan Apaydın * - JD Isaacks */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count godina|:count godine|:count godina', 'y' => ':count godina|:count godine|:count godina', @@ -55,7 +58,7 @@ return [ 'calendar' => [ 'sameDay' => '[danas u] LT', 'nextDay' => '[sutra u] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $current) { + 'nextWeek' => function (CarbonInterface $current) { switch ($current->dayOfWeek) { case 0: return '[u] [nedjelju] [u] LT'; @@ -68,7 +71,7 @@ return [ } }, 'lastDay' => '[jučer u] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { switch ($current->dayOfWeek) { case 0: case 3: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_BA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_BA.php index 4dd21bab..0a591176 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_BA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_BA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/bs.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Cyrl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Cyrl.php index 09221e0a..e1a17447 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Cyrl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Cyrl.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/bs.php', [ 'meridiem' => ['пре подне', 'поподне'], 'weekdays' => ['недјеља', 'понедјељак', 'уторак', 'сриједа', 'четвртак', 'петак', 'субота'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Latn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Latn.php index 91ed1cc8..b4e363e7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Latn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/bs_Latn.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/bs.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca.php index 5c914397..b8b19946 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca.php @@ -21,6 +21,9 @@ * - Xavi * - qcardona */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count any|:count anys', 'a_year' => 'un any|:count anys', @@ -69,19 +72,19 @@ return [ 'LLLL' => 'dddd D MMMM [de] YYYY [a les] H:mm', ], 'calendar' => [ - 'sameDay' => function (\Carbon\CarbonInterface $current) { + 'sameDay' => function (CarbonInterface $current) { return '[avui a '.($current->hour !== 1 ? 'les' : 'la').'] LT'; }, - 'nextDay' => function (\Carbon\CarbonInterface $current) { + 'nextDay' => function (CarbonInterface $current) { return '[demà a '.($current->hour !== 1 ? 'les' : 'la').'] LT'; }, - 'nextWeek' => function (\Carbon\CarbonInterface $current) { + 'nextWeek' => function (CarbonInterface $current) { return 'dddd [a '.($current->hour !== 1 ? 'les' : 'la').'] LT'; }, - 'lastDay' => function (\Carbon\CarbonInterface $current) { + 'lastDay' => function (CarbonInterface $current) { return '[ahir a '.($current->hour !== 1 ? 'les' : 'la').'] LT'; }, - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { return '[el] dddd [passat a '.($current->hour !== 1 ? 'les' : 'la').'] LT'; }, 'sameElse' => 'L', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_AD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_AD.php index f5718c39..861acd2a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_AD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_AD.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ca.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES.php index 84236064..50049786 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ca.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php index f5718c39..861acd2a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ca.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_FR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_FR.php index f5718c39..861acd2a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_FR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_FR.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ca.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_IT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_IT.php index f5718c39..861acd2a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_IT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_IT.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ca.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp.php index ec616a77..99c1dcac 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['𑄢𑄧𑄝𑄨𑄝𑄢𑄴', '𑄥𑄧𑄟𑄴𑄝𑄢𑄴', '𑄟𑄧𑄁𑄉𑄧𑄣𑄴𑄝𑄢𑄴', '𑄝𑄪𑄖𑄴𑄝𑄢𑄴', '𑄝𑄳𑄢𑄨𑄥𑄪𑄛𑄴𑄝𑄢𑄴', '𑄥𑄪𑄇𑄴𑄇𑄮𑄢𑄴𑄝𑄢𑄴', '𑄥𑄧𑄚𑄨𑄝𑄢𑄴'], 'weekdays_short' => ['𑄢𑄧𑄝𑄨', '𑄥𑄧𑄟𑄴', '𑄟𑄧𑄁𑄉𑄧𑄣𑄴', '𑄝𑄪𑄖𑄴', '𑄝𑄳𑄢𑄨𑄥𑄪𑄛𑄴', '𑄥𑄪𑄇𑄴𑄇𑄮𑄢𑄴', '𑄥𑄧𑄚𑄨'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp_IN.php index 18bd1224..c1fa8af0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ccp_IN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ccp.php', [ 'weekend' => [0, 0], ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cgg.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cgg.php index e4244082..09bcc1c7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cgg.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cgg.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Sande', 'Orwokubanza', 'Orwakabiri', 'Orwakashatu', 'Orwakana', 'Orwakataano', 'Orwamukaaga'], 'weekdays_short' => ['SAN', 'ORK', 'OKB', 'OKS', 'OKN', 'OKT', 'OMK'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs_CZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs_CZ.php index a16a3467..ea2517e8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs_CZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs_CZ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/cs.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cu.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cu.php index 02c983aa..d6d13128 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cu.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cu.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'months' => ['M01', 'M02', 'M03', 'M04', 'M05', 'M06', 'M07', 'M08', 'M09', 'M10', 'M11', 'M12'], 'months_short' => ['M01', 'M02', 'M03', 'M04', 'M05', 'M06', 'M07', 'M08', 'M09', 'M10', 'M11', 'M12'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv.php index cec1fc91..8aeb73aa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv.php @@ -32,7 +32,7 @@ return [ 'a_second' => '{1}пӗр-ик ҫеккунт|:count ҫеккунт', 'ago' => ':time каялла', 'from_now' => function ($time) { - return $time.(preg_match('/сехет$/', $time) ? 'рен' : (preg_match('/ҫул/', $time) ? 'тан' : 'ран')); + return $time.(preg_match('/сехет$/u', $time) ? 'рен' : (preg_match('/ҫул/u', $time) ? 'тан' : 'ран')); }, 'diff_yesterday' => 'Ӗнер', 'diff_today' => 'Паян', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv_RU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv_RU.php index ddff8931..197bd8d3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv_RU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cv_RU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/cv.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy_GB.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy_GB.php index 541127c6..2c8148d0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy_GB.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy_GB.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/cy.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_DK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_DK.php index b3bac1a9..392c4841 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_DK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_DK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/da.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_GL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_GL.php index b2ba81f5..ea5698b9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_GL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da_GL.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/da.php', [ 'formats' => [ 'L' => 'DD/MM/YYYY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dav.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dav.php index 79f021e1..e95ec4bb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dav.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dav.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Luma lwa K', 'luma lwa p'], 'weekdays' => ['Ituku ja jumwa', 'Kuramuka jimweri', 'Kuramuka kawi', 'Kuramuka kadadu', 'Kuramuka kana', 'Kuramuka kasanu', 'Kifula nguwo'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de_LI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de_LI.php index 82edfa1d..03e606a6 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de_LI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de_LI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/de.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dje.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dje.php index 08ddbf13..74b7ac12 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dje.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dje.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Subbaahi', 'Zaarikay b'], 'weekdays' => ['Alhadi', 'Atinni', 'Atalaata', 'Alarba', 'Alhamisi', 'Alzuma', 'Asibti'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dua.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dua.php index 65d712f5..55e5c7c3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dua.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dua.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['idiɓa', 'ebyámu'], 'weekdays' => ['éti', 'mɔ́sú', 'kwasú', 'mukɔ́sú', 'ŋgisú', 'ɗónɛsú', 'esaɓasú'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv.php index a2b60dff..4b8d7e1a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + $months = [ 'ޖެނުއަރީ', 'ފެބްރުއަރީ', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv_MV.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv_MV.php index 208fb5a3..2668d5b0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv_MV.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dv_MV.php @@ -3,7 +3,7 @@ /** * This file is part of the Carbon package. * - * (c) Ahmed Ali + * (c) Brian Nesbitt * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dyo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dyo.php index ecb649b0..33082e67 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dyo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/dyo.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Dimas', 'Teneŋ', 'Talata', 'Alarbay', 'Aramisay', 'Arjuma', 'Sibiti'], 'weekdays_short' => ['Dim', 'Ten', 'Tal', 'Ala', 'Ara', 'Arj', 'Sib'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ebu.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ebu.php index 5aab48d9..f60bc6f2 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ebu.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ebu.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['KI', 'UT'], 'weekdays' => ['Kiumia', 'Njumatatu', 'Njumaine', 'Njumatano', 'Aramithi', 'Njumaa', 'NJumamothii'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee.php index 2fd9dcd8..f96c5c9d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['ŋ', 'ɣ'], 'weekdays' => ['kɔsiɖa', 'dzoɖa', 'blaɖa', 'kuɖa', 'yawoɖa', 'fiɖa', 'memleɖa'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee_TG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee_TG.php index 02d77e6d..7a8b36c9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee_TG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ee_TG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ee.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/el.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/el.php index 09cf7e89..7c40f9c1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/el.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/el.php @@ -19,6 +19,9 @@ * - yiannisdesp * - Ilias Kasmeridis (iliaskasm) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count χρόνος|:count χρόνια', 'a_year' => 'ένας χρόνος|:count χρόνια', @@ -65,7 +68,7 @@ return [ 'nextDay' => '[Αύριο {}] LT', 'nextWeek' => 'dddd [{}] LT', 'lastDay' => '[Χθες {}] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { switch ($current->dayOfWeek) { case 6: return '[το προηγούμενο] dddd [{}] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_001.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_001.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_001.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_001.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_150.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_150.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_150.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_150.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AI.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AS.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AS.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AT.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_AT.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BB.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BB.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BB.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BB.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BE.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BE.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BI.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BM.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BM.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BS.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BS.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BW.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BW.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BZ.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_BZ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CC.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CK.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CM.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CM.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CX.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CX.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CX.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CX.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DE.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DE.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DG.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DM.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_DM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ER.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ER.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ER.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ER.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FI.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FJ.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FJ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FK.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FM.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_FM.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GD.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GD.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GG.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GH.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GH.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GI.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GM.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GM.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GU.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GY.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_GY.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IM.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IM.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IO.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_IO.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ISO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ISO.php index 6ae11c9a..11457b0c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ISO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ISO.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JE.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JE.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JM.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_JM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KE.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KI.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KN.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KY.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_KY.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LC.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LR.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LR.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LS.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_LS.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MG.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MH.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MH.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MO.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MP.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MP.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MP.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MP.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MS.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MS.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MT.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MT.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MU.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MU.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MW.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MW.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MY.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_MY.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NA.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NA.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NF.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NF.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NG.php index 1d0d34ff..67bceaad 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'formats' => [ 'L' => 'DD/MM/YY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NL.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NL.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NR.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NR.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NU.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_NU.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PG.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PK.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PN.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PR.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PW.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_PW.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_RW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_RW.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_RW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_RW.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SB.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SB.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SB.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SB.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SC.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SD.php index ce4780c6..c4e2557e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SD.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 6, 'weekend' => [5, 6], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SE.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SE.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SG.php index ed0b3f93..5ee95241 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'from_now' => 'in :time', 'formats' => [ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SH.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SH.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SI.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SL.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SL.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SS.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SS.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SX.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SX.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SX.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SX.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SZ.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_SZ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TC.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TK.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TO.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TO.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TT.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TT.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TV.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TV.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TV.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TV.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TZ.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_TZ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UG.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UM.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_UM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US_Posix.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US_Posix.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US_Posix.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_US_Posix.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VC.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VG.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VI.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VU.php index 9f2a3f74..e2dd81db 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_VU.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_WS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_WS.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_WS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_WS.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ZW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ZW.php index 31f60e19..f086dc63 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ZW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_ZW.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/en.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php index daaf2570..f77ec39c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php @@ -27,6 +27,9 @@ * - Daniel Commesse Liévanos (danielcommesse) * - Pete Scopes (pdscopes) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count año|:count años', 'a_year' => 'un año|:count años', @@ -77,19 +80,19 @@ return [ 'LLLL' => 'dddd, D [de] MMMM [de] YYYY H:mm', ], 'calendar' => [ - 'sameDay' => function (\Carbon\CarbonInterface $current) { + 'sameDay' => function (CarbonInterface $current) { return '[hoy a la'.($current->hour !== 1 ? 's' : '').'] LT'; }, - 'nextDay' => function (\Carbon\CarbonInterface $current) { + 'nextDay' => function (CarbonInterface $current) { return '[mañana a la'.($current->hour !== 1 ? 's' : '').'] LT'; }, - 'nextWeek' => function (\Carbon\CarbonInterface $current) { + 'nextWeek' => function (CarbonInterface $current) { return 'dddd [a la'.($current->hour !== 1 ? 's' : '').'] LT'; }, - 'lastDay' => function (\Carbon\CarbonInterface $current) { + 'lastDay' => function (CarbonInterface $current) { return '[ayer a la'.($current->hour !== 1 ? 's' : '').'] LT'; }, - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { return '[el] dddd [pasado a la'.($current->hour !== 1 ? 's' : '').'] LT'; }, 'sameElse' => 'L', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BR.php index e9dbe2b9..378d0547 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BR.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 0, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BZ.php index e9dbe2b9..378d0547 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_BZ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 0, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_CU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_CU.php index 96391d47..f02e1a66 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_CU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_CU.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_EA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_EA.php index 96391d47..f02e1a66 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_EA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_EA.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_GQ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_GQ.php index 96391d47..f02e1a66 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_GQ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_GQ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_IC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_IC.php index 96391d47..f02e1a66 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_IC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_IC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_PH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_PH.php index ea345b21..deae06a1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_PH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es_PH.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es.php', [ 'first_day_of_week' => 0, 'formats' => [ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/et_EE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/et_EE.php index 3588f627..0f112b34 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/et_EE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/et_EE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/et.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/eu_ES.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/eu_ES.php index 442cca79..0d1e82a9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/eu_ES.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/eu_ES.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/eu.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ewo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ewo.php index f5ae8cf9..7808ab50 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ewo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ewo.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['kíkíríg', 'ngəgógəle'], 'weekdays' => ['sɔ́ndɔ', 'mɔ́ndi', 'sɔ́ndɔ məlú mə́bɛ̌', 'sɔ́ndɔ məlú mə́lɛ́', 'sɔ́ndɔ məlú mə́nyi', 'fúladé', 'séradé'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_AF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_AF.php index 06566fa4..69471004 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_AF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_AF.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fa.php', [ 'meridiem' => ['ق', 'ب'], 'weekend' => [4, 5], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_IR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_IR.php index 6d1832c2..08d01825 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_IR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fa_IR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fa.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_CM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_CM.php index dafa98e3..b797ac09 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_CM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_CM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ff.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_GN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_GN.php index dafa98e3..b797ac09 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_GN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_GN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ff.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_MR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_MR.php index 65276d3f..2f4c29f6 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_MR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ff_MR.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ff.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi_FI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi_FI.php index 3597fa22..920f1caa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi_FI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi_FI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fi.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_DK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_DK.php index e0f45378..657f2c5b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_DK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_DK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fo.php', [ 'formats' => [ 'L' => 'DD.MM.yy', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_FO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_FO.php index 6a4bc313..6d736167 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_FO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fo_FO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fo.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BF.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BI.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BJ.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BJ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BL.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_BL.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CD.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CD.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CF.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CG.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CI.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CM.php index 52b951cd..67d37878 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_CM.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'meridiem' => ['mat.', 'soir'], ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DJ.php index 40579a46..2f060869 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DJ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'first_day_of_week' => 6, 'formats' => [ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DZ.php index 2c1ab853..ae8db5fa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_DZ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'first_day_of_week' => 6, 'weekend' => [5, 6], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_FR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_FR.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_FR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_FR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GA.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GF.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GN.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GP.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GP.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GP.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GP.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GQ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GQ.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GQ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_GQ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_HT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_HT.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_HT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_HT.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_KM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_KM.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_KM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_KM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MA.php index 7d2b1dbe..1bf034dc 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MA.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'first_day_of_week' => 6, 'weekend' => [5, 6], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MC.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MC.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MF.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MG.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_ML.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_ML.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_ML.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_ML.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MQ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MQ.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MQ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MQ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MR.php index d177a7d7..37cf83f0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MR.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MU.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_MU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NC.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NC.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NE.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_NE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PF.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PM.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_PM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RE.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RW.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_RW.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SC.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SC.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SN.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SY.php index 2c1ab853..ae8db5fa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_SY.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'first_day_of_week' => 6, 'weekend' => [5, 6], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TD.php index d177a7d7..37cf83f0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TD.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TG.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TN.php index d3e26568..6905e7a8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_TN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'weekend' => [5, 6], 'formats' => [ diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_VU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_VU.php index d177a7d7..37cf83f0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_VU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_VU.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fr.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_WF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_WF.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_WF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_WF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_YT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_YT.php index f9801e87..ec3ee359 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_YT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr_YT.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/fr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ga_IE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ga_IE.php index d50630cf..57b0c4fb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ga_IE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ga_IE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ga.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gd_GB.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gd_GB.php index 80da9c65..4fc26b3d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gd_GB.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gd_GB.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/gd.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl.php index 58c1db15..088b0f28 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl.php @@ -17,6 +17,9 @@ * - Diego Vilariño * - Sebastian Thierer */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count ano|:count anos', 'a_year' => 'un ano|:count anos', @@ -65,19 +68,19 @@ return [ 'LLLL' => 'dddd, D [de] MMMM [de] YYYY H:mm', ], 'calendar' => [ - 'sameDay' => function (\Carbon\CarbonInterface $current) { + 'sameDay' => function (CarbonInterface $current) { return '[hoxe '.($current->hour !== 1 ? 'ás' : 'á').'] LT'; }, - 'nextDay' => function (\Carbon\CarbonInterface $current) { + 'nextDay' => function (CarbonInterface $current) { return '[mañá '.($current->hour !== 1 ? 'ás' : 'á').'] LT'; }, - 'nextWeek' => function (\Carbon\CarbonInterface $current) { + 'nextWeek' => function (CarbonInterface $current) { return 'dddd ['.($current->hour !== 1 ? 'ás' : 'á').'] LT'; }, - 'lastDay' => function (\Carbon\CarbonInterface $current) { + 'lastDay' => function (CarbonInterface $current) { return '[onte '.($current->hour !== 1 ? 'á' : 'a').'] LT'; }, - 'lastWeek' => function (\Carbon\CarbonInterface $current) { + 'lastWeek' => function (CarbonInterface $current) { return '[o] dddd [pasado '.($current->hour !== 1 ? 'ás' : 'á').'] LT'; }, 'sameElse' => 'L', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl_ES.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl_ES.php index 12a565ff..9d6c1d96 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl_ES.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gl_ES.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/gl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gom_Latn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gom_Latn.php index 5e54a368..612bb886 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gom_Latn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gom_Latn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return [ 'year' => ':count voros|:count vorsam', 'y' => ':countv', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_CH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_CH.php index 0dba9c54..594eb25d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_CH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_CH.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/gsw.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_FR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_FR.php index e0e7b234..3581dcfb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_FR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_FR.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/gsw.php', [ 'meridiem' => ['vorm.', 'nam.'], 'months' => ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'Auguscht', 'Septämber', 'Oktoober', 'Novämber', 'Dezämber'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_LI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_LI.php index e0e7b234..3581dcfb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_LI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gsw_LI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/gsw.php', [ 'meridiem' => ['vorm.', 'nam.'], 'months' => ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'Auguscht', 'Septämber', 'Oktoober', 'Novämber', 'Dezämber'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu.php index 7c7872bc..8bc43114 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu.php @@ -18,7 +18,7 @@ return [ 'year' => 'એક વર્ષ|:count વર્ષ', 'y' => ':countવર્ષ|:countવર્ષો', - 'month' => 'એક મહિનો|:count મહિનો', + 'month' => 'એક મહિનો|:count મહિના', 'm' => ':countમહિનો|:countમહિના', 'week' => ':count અઠવાડિયું|:count અઠવાડિયા', 'w' => ':countઅઠ.|:countઅઠ.', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu_IN.php index c5784408..02654b1f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/gu_IN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/gu.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/guz.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/guz.php index aa9769ce..6230165c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/guz.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/guz.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Ma', 'Mo'], 'weekdays' => ['Chumapiri', 'Chumatato', 'Chumaine', 'Chumatano', 'Aramisi', 'Ichuma', 'Esabato'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_GH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_GH.php index bce5e415..f9f99a73 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_GH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_GH.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ha.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NE.php index bce5e415..f9f99a73 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ha.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NG.php index bce5e415..f9f99a73 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ha_NG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ha.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/haw.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/haw.php index 51715d8e..cdd36861 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/haw.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/haw.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'months' => ['Ianuali', 'Pepeluali', 'Malaki', 'ʻApelila', 'Mei', 'Iune', 'Iulai', 'ʻAukake', 'Kepakemapa', 'ʻOkakopa', 'Nowemapa', 'Kekemapa'], 'months_short' => ['Ian.', 'Pep.', 'Mal.', 'ʻAp.', 'Mei', 'Iun.', 'Iul.', 'ʻAu.', 'Kep.', 'ʻOk.', 'Now.', 'Kek.'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/he_IL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/he_IL.php index 57c4fec8..14fab3e9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/he_IL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/he_IL.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/he.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hi_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hi_IN.php index ac302995..749dd97c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hi_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hi_IN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/hi.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr.php index acb7e92c..cfd85fd4 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr.php @@ -27,6 +27,9 @@ * - Stjepan Majdak * - Vanja Retkovac (vr00) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count godinu|:count godine|:count godina', 'y' => ':count god.|:count god.|:count god.', @@ -67,7 +70,7 @@ return [ 'calendar' => [ 'sameDay' => '[danas u] LT', 'nextDay' => '[sutra u] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $date) { + 'nextWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[u] [nedjelju] [u] LT'; @@ -80,7 +83,7 @@ return [ } }, 'lastDay' => '[jučer u] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: case 3: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr_HR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr_HR.php index 2ae141dc..db74d8c7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr_HR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hr_HR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/hr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php index 673f9dc4..b2d2ac11 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php @@ -15,6 +15,9 @@ * - Brett Johnson * - balping */ + +use Carbon\CarbonInterface; + $huWeekEndings = ['vasárnap', 'hétfőn', 'kedden', 'szerdán', 'csütörtökön', 'pénteken', 'szombaton']; return [ @@ -99,11 +102,11 @@ return [ 'calendar' => [ 'sameDay' => '[ma] LT[-kor]', 'nextDay' => '[holnap] LT[-kor]', - 'nextWeek' => function (\Carbon\CarbonInterface $date) use ($huWeekEndings) { + 'nextWeek' => function (CarbonInterface $date) use ($huWeekEndings) { return '['.$huWeekEndings[$date->dayOfWeek].'] LT[-kor]'; }, 'lastDay' => '[tegnap] LT[-kor]', - 'lastWeek' => function (\Carbon\CarbonInterface $date) use ($huWeekEndings) { + 'lastWeek' => function (CarbonInterface $date) use ($huWeekEndings) { return '[múlt '.$huWeekEndings[$date->dayOfWeek].'] LT[-kor]'; }, 'sameElse' => 'L', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu_HU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu_HU.php index b33a6319..b1c48541 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu_HU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu_HU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/hu.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/i18n.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/i18n.php index d19e4f40..e65449b8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/i18n.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/i18n.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'formats' => [ 'L' => 'YYYY-MM-DD', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/id_ID.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/id_ID.php index 406112af..d5953a14 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/id_ID.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/id_ID.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/id.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ii.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ii.php index 30f83740..a4246c27 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ii.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ii.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['ꎸꄑ', 'ꁯꋒ'], 'weekdays' => ['ꑭꆏꑍ', 'ꆏꊂꋍ', 'ꆏꊂꑍ', 'ꆏꊂꌕ', 'ꆏꊂꇖ', 'ꆏꊂꉬ', 'ꆏꊂꃘ'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/in.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/in.php index 406112af..d5953a14 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/in.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/in.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/id.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/is_IS.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/is_IS.php index 8b91bb23..4d35c448 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/is_IS.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/is_IS.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/is.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php index c23d8db1..605bcbb5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php @@ -22,6 +22,9 @@ * - Davide Casiraghi (davide-casiraghi) * - Pete Scopes (pdscopes) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count anno|:count anni', 'a_year' => 'un anno|:count anni', @@ -81,7 +84,7 @@ return [ 'nextDay' => '[Domani alle] LT', 'nextWeek' => 'dddd [alle] LT', 'lastDay' => '[Ieri alle] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[la scorsa] dddd [alle] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_SM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_SM.php index 57fab39a..5e8fc92f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_SM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_SM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/it.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_VA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_VA.php index 57fab39a..5e8fc92f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_VA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it_VA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/it.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/iw.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/iw.php index a8034e83..a26e3506 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/iw.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/iw.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'months' => ['ינואר', 'פברואר', 'מרץ', 'אפריל', 'מאי', 'יוני', 'יולי', 'אוגוסט', 'ספטמבר', 'אוקטובר', 'נובמבר', 'דצמבר'], 'months_short' => ['ינו׳', 'פבר׳', 'מרץ', 'אפר׳', 'מאי', 'יוני', 'יולי', 'אוג׳', 'ספט׳', 'אוק׳', 'נוב׳', 'דצמ׳'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja.php index fa4cb367..1ca67519 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja.php @@ -21,6 +21,9 @@ * - toyama satoshi * - atakigawa */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count年', 'y' => ':count年', @@ -56,7 +59,7 @@ return [ 'calendar' => [ 'sameDay' => '[今日] LT', 'nextDay' => '[明日] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $current, \Carbon\CarbonInterface $other) { + 'nextWeek' => function (CarbonInterface $current, CarbonInterface $other) { if ($other->week !== $current->week) { return '[来週]dddd LT'; } @@ -64,7 +67,7 @@ return [ return 'dddd LT'; }, 'lastDay' => '[昨日] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $current, \Carbon\CarbonInterface $other) { + 'lastWeek' => function (CarbonInterface $current, CarbonInterface $other) { if ($other->week !== $current->week) { return '[先週]dddd LT'; } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja_JP.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja_JP.php index 9e035fdb..c2836253 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja_JP.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ja_JP.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ja.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jgo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jgo.php index bad6beb7..6a1e77a8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jgo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jgo.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jmc.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jmc.php index f8cc72c1..ed92e8e7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jmc.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/jmc.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['utuko', 'kyiukonyi'], 'weekdays' => ['Jumapilyi', 'Jumatatuu', 'Jumanne', 'Jumatanu', 'Alhamisi', 'Ijumaa', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka.php index 5ddb957d..a5d563d3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka.php @@ -24,6 +24,9 @@ * - Avtandil Kikabidze (akalongman) * - Levan Velijanashvili (Stichoza) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count წელი', 'y' => ':count წელი', @@ -149,7 +152,7 @@ return [ 'calendar' => [ 'sameDay' => '[დღეს], LT[-ზე]', 'nextDay' => '[ხვალ], LT[-ზე]', - 'nextWeek' => function (\Carbon\CarbonInterface $current, \Carbon\CarbonInterface $other) { + 'nextWeek' => function (CarbonInterface $current, CarbonInterface $other) { return ($current->isSameWeek($other) ? '' : '[შემდეგ] ').'dddd, LT[-ზე]'; }, 'lastDay' => '[გუშინ], LT[-ზე]', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka_GE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka_GE.php index dd77fa3e..a26d9305 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka_GE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ka_GE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ka.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kam.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kam.php index 0fb6b2ea..0fc70d70 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kam.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kam.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Ĩyakwakya', 'Ĩyawĩoo'], 'weekdays' => ['Wa kyumwa', 'Wa kwambĩlĩlya', 'Wa kelĩ', 'Wa katatũ', 'Wa kana', 'Wa katano', 'Wa thanthatũ'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kde.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kde.php index 8acdaba3..fbcc9f3d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kde.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kde.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Muhi', 'Chilo'], 'weekdays' => ['Liduva lyapili', 'Liduva lyatatu', 'Liduva lyanchechi', 'Liduva lyannyano', 'Liduva lyannyano na linji', 'Liduva lyannyano na mavili', 'Liduva litandi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kea.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kea.php index 8a334e24..8b6c21b9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kea.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kea.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['a', 'p'], 'weekdays' => ['dumingu', 'sigunda-fera', 'tersa-fera', 'kuarta-fera', 'kinta-fera', 'sesta-fera', 'sabadu'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/khq.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/khq.php index f0649e7c..7a834cf0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/khq.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/khq.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Adduha', 'Aluula'], 'weekdays' => ['Alhadi', 'Atini', 'Atalata', 'Alarba', 'Alhamiisa', 'Aljuma', 'Assabdu'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ki.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ki.php index 5754ffc1..d86afc50 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ki.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ki.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Kiroko', 'Hwaĩ-inĩ'], 'weekdays' => ['Kiumia', 'Njumatatũ', 'Njumaine', 'Njumatana', 'Aramithi', 'Njumaa', 'Njumamothi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kk_KZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kk_KZ.php index af4a5b2b..7dc5ebcc 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kk_KZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kk_KZ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/kk.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kkj.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kkj.php index bad6beb7..6a1e77a8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kkj.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kkj.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kln.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kln.php index b034ba50..b9c39968 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kln.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kln.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['krn', 'koosk'], 'weekdays' => ['Kotisap', 'Kotaai', 'Koaeng’', 'Kosomok', 'Koang’wan', 'Komuut', 'Kolo'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/km_KH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/km_KH.php index ef3b415e..92e5fdbd 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/km_KH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/km_KH.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/km.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kn_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kn_IN.php index 7c6c9096..30e3d886 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kn_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/kn_IN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/kn.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KP.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KP.php index 55b40fa2..4ba802b3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KP.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KP.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ko.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KR.php index d8eba2cb..9d873a27 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ko_KR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ko.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksb.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksb.php index 424099dc..aaa00614 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksb.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksb.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['makeo', 'nyiaghuo'], 'weekdays' => ['Jumaapii', 'Jumaatatu', 'Jumaane', 'Jumaatano', 'Alhamisi', 'Ijumaa', 'Jumaamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksf.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksf.php index 8fb55989..84a59672 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksf.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksf.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['sárúwá', 'cɛɛ́nko'], 'weekdays' => ['sɔ́ndǝ', 'lǝndí', 'maadí', 'mɛkrɛdí', 'jǝǝdí', 'júmbá', 'samdí'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksh.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksh.php index 44c60a4d..95457e24 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksh.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ksh.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['v.M.', 'n.M.'], 'weekdays' => ['Sunndaach', 'Mohndaach', 'Dinnsdaach', 'Metwoch', 'Dunnersdaach', 'Friidaach', 'Samsdaach'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku_TR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku_TR.php index 11fce2d8..4243a82f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku_TR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku_TR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ku.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ky_KG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ky_KG.php index 4426bea4..9923a31e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ky_KG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ky_KG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ky.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lag.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lag.php index dc959c96..f3f57f6a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lag.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lag.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['TOO', 'MUU'], 'weekdays' => ['Jumapíiri', 'Jumatátu', 'Jumaíne', 'Jumatáano', 'Alamíisi', 'Ijumáa', 'Jumamóosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb.php index db048342..7636655e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb.php @@ -16,6 +16,9 @@ * - dan-nl * - Simon Lelorrain (slelorrain) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count Joer', 'y' => ':countJ', @@ -57,7 +60,7 @@ return [ 'nextDay' => '[Muer um] LT', 'nextWeek' => 'dddd [um] LT', 'lastDay' => '[Gëschter um] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { // Different date string for 'Dënschdeg' (Tuesday) and 'Donneschdeg' (Thursday) due to phonological rule switch ($date->dayOfWeek) { case 2: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb_LU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb_LU.php index c8625fe9..414bd4d0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb_LU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lb_LU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/lb.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lkt.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lkt.php index 968b0588..ae73a97b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lkt.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lkt.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'month' => ':count haŋwí', // less reliable diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_AO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_AO.php index e244096c..7fdb7f1b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_AO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_AO.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ln.php', [ 'weekdays' => ['eyenga', 'mokɔlɔ mwa yambo', 'mokɔlɔ mwa míbalé', 'mokɔlɔ mwa mísáto', 'mokɔlɔ ya mínéi', 'mokɔlɔ ya mítáno', 'mpɔ́sɔ'], 'weekdays_short' => ['eye', 'ybo', 'mbl', 'mst', 'min', 'mtn', 'mps'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CF.php index e244096c..7fdb7f1b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CF.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ln.php', [ 'weekdays' => ['eyenga', 'mokɔlɔ mwa yambo', 'mokɔlɔ mwa míbalé', 'mokɔlɔ mwa mísáto', 'mokɔlɔ ya mínéi', 'mokɔlɔ ya mítáno', 'mpɔ́sɔ'], 'weekdays_short' => ['eye', 'ybo', 'mbl', 'mst', 'min', 'mtn', 'mps'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CG.php index e244096c..7fdb7f1b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ln_CG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ln.php', [ 'weekdays' => ['eyenga', 'mokɔlɔ mwa yambo', 'mokɔlɔ mwa míbalé', 'mokɔlɔ mwa mísáto', 'mokɔlɔ ya mínéi', 'mokɔlɔ ya mítáno', 'mpɔ́sɔ'], 'weekdays_short' => ['eye', 'ybo', 'mbl', 'mst', 'min', 'mtn', 'mps'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lo_LA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lo_LA.php index c0a1d6b4..9b7fd9bf 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lo_LA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lo_LA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/lo.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc.php index 10661bb0..546e6791 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'minute' => ':count هنر', // less reliable diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc_IQ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc_IQ.php index 449d8632..d42f5e97 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc_IQ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lrc_IQ.php @@ -8,5 +8,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/lrc.php', [ ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lt_LT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lt_LT.php index c3087f4e..f772d38b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lt_LT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lt_LT.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/lt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lu.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lu.php index 8dab5417..c8cd83af 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lu.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lu.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Dinda', 'Dilolo'], 'weekdays' => ['Lumingu', 'Nkodya', 'Ndàayà', 'Ndangù', 'Njòwa', 'Ngòvya', 'Lubingu'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luo.php index 201ca969..b55af731 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luo.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['OD', 'OT'], 'weekdays' => ['Jumapil', 'Wuok Tich', 'Tich Ariyo', 'Tich Adek', 'Tich Ang’wen', 'Tich Abich', 'Ngeso'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luy.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luy.php index 52191253..2b37e3e3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luy.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/luy.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Jumapiri', 'Jumatatu', 'Jumanne', 'Jumatano', 'Murwa wa Kanne', 'Murwa wa Katano', 'Jumamosi'], 'weekdays_short' => ['J2', 'J3', 'J4', 'J5', 'Al', 'Ij', 'J1'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php index 724b58df..693eceb5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php @@ -1,5 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + use Carbon\CarbonInterface; /** @@ -168,6 +177,6 @@ return [ 'weekdays_short' => ['Sv.', 'P.', 'O.', 'T.', 'C.', 'Pk.', 'S.'], 'weekdays_min' => ['Sv.', 'P.', 'O.', 'T.', 'C.', 'Pk.', 'S.'], 'months' => ['janvārī', 'februārī', 'martā', 'aprīlī', 'maijā', 'jūnijā', 'jūlijā', 'augustā', 'septembrī', 'oktobrī', 'novembrī', 'decembrī'], - 'months_short' => ['Janv', 'Feb', 'Mar', 'Apr', 'Mai', 'Jūn', 'Jūl', 'Aug', 'Sept', 'Okt', 'Nov', 'Dec'], + 'months_short' => ['janv.', 'febr.', 'martā', 'apr.', 'maijā', 'jūn.', 'jūl.', 'aug.', 'sept.', 'okt.', 'nov.', 'dec.'], 'meridiem' => ['priekšpusdiena', 'pēcpusdiena'], ]; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv_LV.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv_LV.php index 46c0f430..ee91c369 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv_LV.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv_LV.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/lv.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas.php index 723ae67e..cbd610c2 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Ɛnkakɛnyá', 'Ɛndámâ'], 'weekdays' => ['Jumapílí', 'Jumatátu', 'Jumane', 'Jumatánɔ', 'Alaámisi', 'Jumáa', 'Jumamósi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas_TZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas_TZ.php index aa382b72..56e29053 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas_TZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mas_TZ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/mas.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mer.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mer.php index cb7ba8d7..2e14597f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mer.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mer.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['RŨ', 'ŨG'], 'weekdays' => ['Kiumia', 'Muramuko', 'Wairi', 'Wethatu', 'Wena', 'Wetano', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgh.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgh.php index 65798a80..2a80960d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgh.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgh.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['wichishu', 'mchochil’l'], 'weekdays' => ['Sabato', 'Jumatatu', 'Jumanne', 'Jumatano', 'Arahamisi', 'Ijumaa', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgo.php index a5a07543..a126c9ff 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mgo.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Aneg 1', 'Aneg 2', 'Aneg 3', 'Aneg 4', 'Aneg 5', 'Aneg 6', 'Aneg 7'], 'weekdays_short' => ['Aneg 1', 'Aneg 2', 'Aneg 3', 'Aneg 4', 'Aneg 5', 'Aneg 6', 'Aneg 7'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mi_NZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mi_NZ.php index 123d2292..6b964e3a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mi_NZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mi_NZ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/mi.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/miq_NI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/miq_NI.php index b56783ee..57faa318 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/miq_NI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/miq_NI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'formats' => [ 'L' => 'DD/MM/YY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk.php index 853bc96d..d822de09 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk.php @@ -19,6 +19,9 @@ * - JD Isaacks * - Tomi Atanasoski */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count година|:count години', 'a_year' => 'година|:count години', @@ -65,7 +68,7 @@ return [ 'nextDay' => '[Утре во] LT', 'nextWeek' => '[Во] dddd [во] LT', 'lastDay' => '[Вчера во] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: case 3: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk_MK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk_MK.php index 06ff7d9d..95e2ff9c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk_MK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mk_MK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/mk.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ml_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ml_IN.php index 20878dce..000e7958 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ml_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ml_IN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ml.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php index 25f65b33..717d199b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php @@ -5,11 +5,8 @@ * * (c) Brian Nesbitt * - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. - * - * @translator Batmandakh Erdenebileg */ /* diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn_MN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn_MN.php index b8fef24c..e5ce426c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn_MN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn_MN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/mn.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mo.php index dd7c8f09..102afcde 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mo.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ro.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mr_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mr_IN.php index 556cefa2..7bca919f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mr_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mr_IN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/mr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php index ed7d48f8..36934eeb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php @@ -75,12 +75,18 @@ return [ 'sameElse' => 'L', ], 'meridiem' => function ($hour) { + if ($hour < 1) { + return 'tengah malam'; + } + if ($hour < 12) { return 'pagi'; } - if ($hour < 15) { + + if ($hour < 13) { return 'tengah hari'; } + if ($hour < 19) { return 'petang'; } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_BN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_BN.php index ea2b453b..ef837a2d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_BN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_BN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ms.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_SG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_SG.php index 097a168f..77cb83d2 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_SG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms_SG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ms.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mt_MT.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mt_MT.php index 6ec2b339..9534f687 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mt_MT.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mt_MT.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/mt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mua.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mua.php index 8f1f9dcb..a3a3c6fd 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mua.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mua.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['comme', 'lilli'], 'weekdays' => ['Com’yakke', 'Comlaaɗii', 'Comzyiiɗii', 'Comkolle', 'Comkaldǝɓlii', 'Comgaisuu', 'Comzyeɓsuu'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/my_MM.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/my_MM.php index 1f27ccae..a0108dd4 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/my_MM.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/my_MM.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/my.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mzn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mzn.php index 6ad36042..70f5f23c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mzn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mzn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fa.php', [ 'months' => ['ژانویه', 'فوریه', 'مارس', 'آوریل', 'مه', 'ژوئن', 'ژوئیه', 'اوت', 'سپتامبر', 'اکتبر', 'نوامبر', 'دسامبر'], 'months_short' => ['ژانویه', 'فوریه', 'مارس', 'آوریل', 'مه', 'ژوئن', 'ژوئیه', 'اوت', 'سپتامبر', 'اکتبر', 'نوامبر', 'دسامبر'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/naq.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/naq.php index 614ced43..fbd9be91 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/naq.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/naq.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['ǁgoagas', 'ǃuias'], 'weekdays' => ['Sontaxtsees', 'Mantaxtsees', 'Denstaxtsees', 'Wunstaxtsees', 'Dondertaxtsees', 'Fraitaxtsees', 'Satertaxtsees'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_NO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_NO.php index bd643a8e..31678c53 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_NO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_NO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/nb.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_SJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_SJ.php index 93cbaef1..ce0210bc 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_SJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nb_SJ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/nb.php', [ 'formats' => [ 'LL' => 'D. MMM YYYY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nd.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nd.php index d6fdaad3..f75d9a71 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nd.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nd.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Sonto', 'Mvulo', 'Sibili', 'Sithathu', 'Sine', 'Sihlanu', 'Mgqibelo'], 'weekdays_short' => ['Son', 'Mvu', 'Sib', 'Sit', 'Sin', 'Sih', 'Mgq'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nds_DE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nds_DE.php index eb6e77e6..a6c57a91 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nds_DE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nds_DE.php @@ -20,36 +20,41 @@ return array_replace_recursive(require __DIR__.'/en.php', [ 'months' => ['Jannuaar', 'Feberwaar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember'], 'months_short' => ['Jan', 'Feb', 'Mär', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dez'], 'weekdays' => ['Sünndag', 'Maandag', 'Dingsdag', 'Middeweek', 'Dunnersdag', 'Freedag', 'Sünnavend'], - 'weekdays_short' => ['Sdag', 'Maan', 'Ding', 'Migg', 'Dunn', 'Free', 'Svd.'], - 'weekdays_min' => ['Sdag', 'Maan', 'Ding', 'Migg', 'Dunn', 'Free', 'Svd.'], + 'weekdays_short' => ['Sdag', 'Maan', 'Ding', 'Midd', 'Dunn', 'Free', 'Svd.'], + 'weekdays_min' => ['Sd', 'Ma', 'Di', 'Mi', 'Du', 'Fr', 'Sa'], 'first_day_of_week' => 1, 'day_of_first_week_of_year' => 4, 'year' => ':count Johr', - 'y' => ':count Johr', - 'a_year' => ':count Johr', + 'y' => ':countJ', + 'a_year' => '{1}een Johr|:count Johr', 'month' => ':count Maand', - 'm' => ':count Maand', - 'a_month' => ':count Maand', + 'm' => ':countM', + 'a_month' => '{1}een Maand|:count Maand', - 'week' => ':count Week', - 'w' => ':count Week', - 'a_week' => ':count Week', + 'week' => ':count Week|:count Weken', + 'w' => ':countW', + 'a_week' => '{1}een Week|:count Week|:count Weken', - 'day' => ':count Dag', - 'd' => ':count Dag', - 'a_day' => ':count Dag', + 'day' => ':count Dag|:count Daag', + 'd' => ':countD', + 'a_day' => '{1}een Dag|:count Dag|:count Daag', - 'hour' => ':count Stünn', - 'h' => ':count Stünn', - 'a_hour' => ':count Stünn', + 'hour' => ':count Stünn|:count Stünnen', + 'h' => ':countSt', + 'a_hour' => '{1}een Stünn|:count Stünn|:count Stünnen', - 'minute' => ':count Minuut', - 'min' => ':count Minuut', - 'a_minute' => ':count Minuut', + 'minute' => ':count Minuut|:count Minuten', + 'min' => ':countm', + 'a_minute' => '{1}een Minuut|:count Minuut|:count Minuten', - 'second' => ':count sekunn', - 's' => ':count sekunn', - 'a_second' => ':count sekunn', + 'second' => ':count Sekunn|:count Sekunnen', + 's' => ':counts', + 'a_second' => 'en poor Sekunnen|:count Sekunn|:count Sekunnen', + + 'ago' => 'vör :time', + 'from_now' => 'in :time', + 'before' => ':time vörher', + 'after' => ':time later', ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_IN.php index 2583bcf8..f68d00e3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_IN.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ne.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_NP.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_NP.php index 38caa1e5..27840c0f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_NP.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ne_NP.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ne.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl.php index fc8b5d9a..2d737703 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl.php @@ -71,9 +71,9 @@ return [ 'period_recurrences' => ':count keer', 'period_interval' => function (string $interval = '') { /** @var string $output */ - $output = preg_replace('/^(een|één|1)\s+/', '', $interval); + $output = preg_replace('/^(een|één|1)\s+/u', '', $interval); - if (preg_match('/^(een|één|1)( jaar|j| uur|u)/', $interval)) { + if (preg_match('/^(een|één|1)( jaar|j| uur|u)/u', $interval)) { return "elk $output"; } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_BQ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_BQ.php index 521d2d69..c269197b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_BQ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_BQ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/nl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_CW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_CW.php index 521d2d69..c269197b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_CW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_CW.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/nl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SR.php index 521d2d69..c269197b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/nl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SX.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SX.php index 521d2d69..c269197b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SX.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nl_SX.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/nl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nmg.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nmg.php index f8850e29..4d1df6e5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nmg.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nmg.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['maná', 'kugú'], 'weekdays' => ['sɔ́ndɔ', 'mɔ́ndɔ', 'sɔ́ndɔ mafú mába', 'sɔ́ndɔ mafú málal', 'sɔ́ndɔ mafú mána', 'mabágá má sukul', 'sásadi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nn_NO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nn_NO.php index ebbe0b78..8e168711 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nn_NO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nn_NO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/nn.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nnh.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nnh.php index fa6a448e..007d2399 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nnh.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nnh.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['mbaʼámbaʼ', 'ncwònzém'], 'weekdays' => null, diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nus.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nus.php index 033e9756..789bc391 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nus.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nus.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['RW', 'TŊ'], 'weekdays' => ['Cäŋ kuɔth', 'Jiec la̱t', 'Rɛw lätni', 'Diɔ̱k lätni', 'Ŋuaan lätni', 'Dhieec lätni', 'Bäkɛl lätni'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nyn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nyn.php index fdc2ff46..8660ea42 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nyn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/nyn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Sande', 'Orwokubanza', 'Orwakabiri', 'Orwakashatu', 'Orwakana', 'Orwakataano', 'Orwamukaaga'], 'weekdays_short' => ['SAN', 'ORK', 'OKB', 'OKS', 'OKN', 'OKT', 'OMK'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php index 94c3e04c..89693e67 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php @@ -14,8 +14,10 @@ * - Quentí */ // @codeCoverageIgnoreStart +use Symfony\Component\Translation\PluralizationRules; + if (class_exists('Symfony\\Component\\Translation\\PluralizationRules')) { - \Symfony\Component\Translation\PluralizationRules::set(function ($number) { + PluralizationRules::set(function ($number) { return $number == 1 ? 0 : 1; }, 'oc'); } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc_FR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc_FR.php index fde859fd..01eb5c14 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc_FR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc_FR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/oc.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_ET.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_ET.php index 46483439..044760e3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_ET.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_ET.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/om.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_KE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_KE.php index b29a40fb..f5a4d1c9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_KE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/om_KE.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/om.php', [ 'day_of_first_week_of_year' => 0, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Arab.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Arab.php index 8b04dee2..39b06532 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Arab.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Arab.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ur.php', [ 'weekdays' => ['اتوار', 'پیر', 'منگل', 'بُدھ', 'جمعرات', 'جمعہ', 'ہفتہ'], 'weekdays_short' => ['اتوار', 'پیر', 'منگل', 'بُدھ', 'جمعرات', 'جمعہ', 'ہفتہ'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Guru.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Guru.php index c0d35ecb..7adff5c3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Guru.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pa_Guru.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/pa.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php index ca10fe4a..f0196c0d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php @@ -25,7 +25,11 @@ * - Peter (UnrulyNatives) * - Qrzysio * - Jan (aso824) + * - diverpl */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count rok|:count lata|:count lat', 'a_year' => 'rok|:count lata|:count lat', @@ -44,12 +48,18 @@ return [ 'h' => ':count godz.', 'minute' => ':count minuta|:count minuty|:count minut', 'a_minute' => 'minuta|:count minuty|:count minut', - 'min' => ':count min.', + 'min' => ':count min', 'second' => ':count sekunda|:count sekundy|:count sekund', 'a_second' => '{1}kilka sekund|:count sekunda|:count sekundy|:count sekund', 's' => ':count sek.', 'ago' => ':time temu', - 'from_now' => 'za :time', + 'from_now' => static function ($time) { + return 'za '.strtr($time, [ + 'godzina' => 'godzinę', + 'minuta' => 'minutę', + 'sekunda' => 'sekundę', + ]); + }, 'after' => ':time po', 'before' => ':time przed', 'diff_now' => 'przed chwilą', @@ -72,7 +82,7 @@ return [ 'calendar' => [ 'sameDay' => '[Dziś o] LT', 'nextDay' => '[Jutro o] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $date) { + 'nextWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[W niedzielę o] LT'; @@ -87,7 +97,7 @@ return [ } }, 'lastDay' => '[Wczoraj o] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[W zeszłą niedzielę o] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl_PL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl_PL.php index 69cd6976..222bcdb4 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl_PL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl_PL.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/prg.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/prg.php index d0fd2f0d..6e63f4ad 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/prg.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/prg.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'months' => ['M01', 'M02', 'M03', 'M04', 'M05', 'M06', 'M07', 'M08', 'M09', 'M10', 'M11', 'M12'], 'months_short' => ['M01', 'M02', 'M03', 'M04', 'M05', 'M06', 'M07', 'M08', 'M09', 'M10', 'M11', 'M12'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ps_AF.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ps_AF.php index e63121e3..6ec51804 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ps_AF.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ps_AF.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ps.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php index e36ca4c3..0af89499 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php @@ -23,6 +23,9 @@ * - Sebastian Thierer * - Claudson Martins (claudsonm) */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count ano|:count anos', 'a_year' => 'um ano|:count anos', @@ -81,7 +84,7 @@ return [ 'nextDay' => '[Amanhã às] LT', 'nextWeek' => 'dddd [às] LT', 'lastDay' => '[Ontem às] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: case 6: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_AO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_AO.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_AO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_AO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CH.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CH.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CV.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CV.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CV.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_CV.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GQ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GQ.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GQ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GQ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GW.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_GW.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_LU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_LU.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_LU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_LU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MO.php index 331fa5cc..f2b5eab7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MO.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/pt.php', [ 'formats' => [ 'LT' => 'h:mm a', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MZ.php index 93bac23d..fbc0c97b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_MZ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/pt.php', [ 'first_day_of_week' => 0, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_ST.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_ST.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_ST.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_ST.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_TL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_TL.php index 3d13bca6..22c01ec5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_TL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt_TL.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/pt.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu.php index 5f3a3924..65278cd1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/es_UY.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_BO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_BO.php index 91635d59..d5db6bf5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_BO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_BO.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/qu.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_EC.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_EC.php index 91635d59..d5db6bf5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_EC.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/qu_EC.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/qu.php', [ 'first_day_of_week' => 1, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rn.php index 637d4e5e..8ab958eb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Z.MU.', 'Z.MW.'], 'weekdays' => ['Ku w’indwi', 'Ku wa mbere', 'Ku wa kabiri', 'Ku wa gatatu', 'Ku wa kane', 'Ku wa gatanu', 'Ku wa gatandatu'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_MD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_MD.php index 0ba6f68a..ad1d2fa8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_MD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_MD.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ro.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_RO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_RO.php index dd7c8f09..102afcde 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_RO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ro_RO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ro.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rof.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rof.php index 80ab454f..205fc266 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rof.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rof.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['kang’ama', 'kingoto'], 'weekdays' => ['Ijumapili', 'Ijumatatu', 'Ijumanne', 'Ijumatano', 'Alhamisi', 'Ijumaa', 'Ijumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru.php index 93e0e01b..673b043b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru.php @@ -35,6 +35,9 @@ * - Vladislav UnsealedOne * - dima-bzz */ + +use Carbon\CarbonInterface; + $transformDiff = function ($input) { return strtr($input, [ 'неделя' => 'неделю', @@ -97,7 +100,7 @@ return [ 'calendar' => [ 'sameDay' => '[Сегодня, в] LT', 'nextDay' => '[Завтра, в] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $current, \Carbon\CarbonInterface $other) { + 'nextWeek' => function (CarbonInterface $current, CarbonInterface $other) { if ($current->week !== $other->week) { switch ($current->dayOfWeek) { case 0: @@ -120,7 +123,7 @@ return [ return '[В] dddd, [в] LT'; }, 'lastDay' => '[Вчера, в] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $current, \Carbon\CarbonInterface $other) { + 'lastWeek' => function (CarbonInterface $current, CarbonInterface $other) { if ($current->week !== $other->week) { switch ($current->dayOfWeek) { case 0: diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_BY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_BY.php index 2c8d78f8..8ca7df34 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_BY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_BY.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ru.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KG.php index 2c8d78f8..8ca7df34 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ru.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KZ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KZ.php index 2c8d78f8..8ca7df34 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KZ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_KZ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ru.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_MD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_MD.php index 2c8d78f8..8ca7df34 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_MD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_MD.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ru.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_RU.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_RU.php index 2c8d78f8..8ca7df34 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_RU.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ru_RU.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ru.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rwk.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rwk.php index f8cc72c1..ed92e8e7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rwk.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/rwk.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['utuko', 'kyiukonyi'], 'weekdays' => ['Jumapilyi', 'Jumatatuu', 'Jumanne', 'Jumatanu', 'Alhamisi', 'Ijumaa', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/saq.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/saq.php index eebfac99..ff8bf604 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/saq.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/saq.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Tesiran', 'Teipa'], 'weekdays' => ['Mderot ee are', 'Mderot ee kuni', 'Mderot ee ong’wan', 'Mderot ee inet', 'Mderot ee ile', 'Mderot ee sapa', 'Mderot ee kwe'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sbp.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sbp.php index 9b737837..e29ca379 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sbp.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sbp.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Lwamilawu', 'Pashamihe'], 'weekdays' => ['Mulungu', 'Jumatatu', 'Jumanne', 'Jumatano', 'Alahamisi', 'Ijumaa', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sd.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sd.php index ad8c0009..0022c5a9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sd.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sd.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + $months = [ 'جنوري', 'فيبروري', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_FI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_FI.php index b2b967ea..cf01805d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_FI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_FI.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/se.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_NO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_NO.php index 83bbf78b..177c7e94 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_NO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_NO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/se.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_SE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_SE.php index 83bbf78b..177c7e94 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_SE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/se_SE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/se.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/seh.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/seh.php index 3ad889ab..babf9afb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/seh.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/seh.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['Dimingu', 'Chiposi', 'Chipiri', 'Chitatu', 'Chinai', 'Chishanu', 'Sabudu'], 'weekdays_short' => ['Dim', 'Pos', 'Pir', 'Tat', 'Nai', 'Sha', 'Sab'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ses.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ses.php index 9355184f..e1099e65 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ses.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ses.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Adduha', 'Aluula'], 'weekdays' => ['Alhadi', 'Atinni', 'Atalaata', 'Alarba', 'Alhamiisa', 'Alzuma', 'Asibti'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sg.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sg.php index 7f8e9daf..9264e893 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sg.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sg.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['ND', 'LK'], 'weekdays' => ['Bikua-ôko', 'Bïkua-ûse', 'Bïkua-ptâ', 'Bïkua-usïö', 'Bïkua-okü', 'Lâpôsö', 'Lâyenga'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php index a953df42..e4aa5a1c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php @@ -8,9 +8,12 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + // @codeCoverageIgnoreStart +use Symfony\Component\Translation\PluralizationRules; + if (class_exists('Symfony\\Component\\Translation\\PluralizationRules')) { - \Symfony\Component\Translation\PluralizationRules::set(function ($number) { + PluralizationRules::set(function ($number) { return (($number % 10 == 1) && ($number % 100 != 11)) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2); }, 'sh'); } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi.php index ee5aa0bc..78151869 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['ⵜⵉⴼⴰⵡⵜ', 'ⵜⴰⴷⴳⴳⵯⴰⵜ'], 'weekdays' => ['ⴰⵙⴰⵎⴰⵙ', 'ⴰⵢⵏⴰⵙ', 'ⴰⵙⵉⵏⴰⵙ', 'ⴰⴽⵕⴰⵙ', 'ⴰⴽⵡⴰⵙ', 'ⵙⵉⵎⵡⴰⵙ', 'ⴰⵙⵉⴹⵢⴰⵙ'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Latn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Latn.php index a5580c30..cddfb242 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Latn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Latn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/shi.php', [ 'meridiem' => ['tifawt', 'tadggʷat'], 'weekdays' => ['asamas', 'aynas', 'asinas', 'akṛas', 'akwas', 'asimwas', 'asiḍyas'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Tfng.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Tfng.php index e51ed130..f3df1f2c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Tfng.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/shi_Tfng.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/shi.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si.php index 289d4d57..636bf691 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si.php @@ -33,7 +33,7 @@ return [ 'a_second' => '{1}තත්පර කිහිපයකට|තත්පර :count', 'ago' => ':time කට පෙර', 'from_now' => function ($time) { - if (preg_match('/දින \d+/', $time)) { + if (preg_match('/දින \d/u', $time)) { return $time.' න්'; } @@ -41,7 +41,7 @@ return [ }, 'before' => ':time කට පෙර', 'after' => function ($time) { - if (preg_match('/දින \d+/', $time)) { + if (preg_match('/දින \d/u', $time)) { return $time.' න්'; } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si_LK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si_LK.php index 6c5be974..81c44e0e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si_LK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/si_LK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/si.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk_SK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk_SK.php index be3d1f24..0515601a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk_SK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk_SK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sk.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php index 56d0f1bf..2e197212 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php @@ -29,6 +29,9 @@ * - Lovro Tramšek (Lovro1107) * - burut13 */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count leto|:count leti|:count leta|:count let', 'y' => ':count leto|:count leti|:count leta|:count let', @@ -96,7 +99,7 @@ return [ 'nextDay' => '[jutri ob] LT', 'nextWeek' => 'dddd [ob] LT', 'lastDay' => '[včeraj ob] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[preteklo] [nedeljo] [ob] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl_SI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl_SI.php index da9fef05..5dad8c81 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl_SI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl_SI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sl.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/smn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/smn.php index b252ebbd..20add023 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/smn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/smn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['ip.', 'ep.'], 'weekdays' => ['pasepeeivi', 'vuossaargâ', 'majebaargâ', 'koskoho', 'tuorâstuv', 'vástuppeeivi', 'lávurduv'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sn.php index 62c82b10..4f25028a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['a', 'p'], 'weekdays' => ['Svondo', 'Muvhuro', 'Chipiri', 'Chitatu', 'China', 'Chishanu', 'Mugovera'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_AL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_AL.php index 0bfbdf3a..ea5df3f2 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_AL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_AL.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sq.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_MK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_MK.php index c844fe0d..62f752c4 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_MK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_MK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sq.php', [ 'formats' => [ 'L' => 'D.M.YYYY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_XK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_XK.php index c844fe0d..62f752c4 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_XK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sq_XK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sq.php', [ 'formats' => [ 'L' => 'D.M.YYYY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr.php index 6ecf2d02..68ba663a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr.php @@ -19,6 +19,9 @@ * - Glavić * - Milos Sakovic */ + +use Carbon\CarbonInterface; + return [ 'year' => ':count godina|:count godine|:count godina', 'y' => ':count g.', @@ -64,7 +67,7 @@ return [ 'calendar' => [ 'sameDay' => '[danas u] LT', 'nextDay' => '[sutra u] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $date) { + 'nextWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[u nedelju u] LT'; @@ -77,7 +80,7 @@ return [ } }, 'lastDay' => '[juče u] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[prošle nedelje u] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php index 85407423..c09df19c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php @@ -20,6 +20,9 @@ * - Nikola Zeravcic * - Milos Sakovic */ + +use Carbon\CarbonInterface; + return [ 'year' => '{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година', 'y' => ':count г.', @@ -63,7 +66,7 @@ return [ 'calendar' => [ 'sameDay' => '[данас у] LT', 'nextDay' => '[сутра у] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $date) { + 'nextWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[у недељу у] LT'; @@ -76,7 +79,7 @@ return [ } }, 'lastDay' => '[јуче у] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[прошле недеље у] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php index 36405d38..0fb63d76 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sr_Cyrl.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php index fb6179ee..d13229ab 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php @@ -14,6 +14,9 @@ * - Glavić * - Milos Sakovic */ + +use Carbon\CarbonInterface; + return [ 'year' => '{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година', 'y' => ':count г.', @@ -60,7 +63,7 @@ return [ 'calendar' => [ 'sameDay' => '[данас у] LT', 'nextDay' => '[сутра у] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $date) { + 'nextWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[у недељу у] LT'; @@ -73,7 +76,7 @@ return [ } }, 'lastDay' => '[јуче у] LT', - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[прошле недеље у] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php index 0643a414..492baf0c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sr_Cyrl_BA.php', [ 'weekdays' => ['недеља', 'понедељак', 'уторак', 'среда', 'четвртак', 'петак', 'субота'], ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn.php index 8ae8c41a..99716747 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php index c25a5072..897c674a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sr_Latn.php', [ 'formats' => [ 'LT' => 'HH:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php index de20f21c..e2133ef1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php @@ -14,6 +14,9 @@ * - Glavić * - Milos Sakovic */ + +use Carbon\CarbonInterface; + return array_replace_recursive(require __DIR__.'/sr.php', [ 'month' => ':count mjesec|:count mjeseca|:count mjeseci', 'week' => ':count nedjelja|:count nedjelje|:count nedjelja', @@ -27,7 +30,7 @@ return array_replace_recursive(require __DIR__.'/sr.php', [ 'diff_tomorrow' => 'sjutra', 'calendar' => [ 'nextDay' => '[sjutra u] LT', - 'nextWeek' => function (\Carbon\CarbonInterface $date) { + 'nextWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[u nedjelju u] LT'; @@ -39,7 +42,7 @@ return array_replace_recursive(require __DIR__.'/sr.php', [ return '[u] dddd [u] LT'; } }, - 'lastWeek' => function (\Carbon\CarbonInterface $date) { + 'lastWeek' => function (CarbonInterface $date) { switch ($date->dayOfWeek) { case 0: return '[prošle nedjelje u] LT'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php index ba7cc097..d0b9d10b 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sr_Latn_BA.php', [ 'weekdays' => ['nedelja', 'ponedeljak', 'utorak', 'sreda', 'četvrtak', 'petak', 'subota'], ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_ME.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_ME.php index b668ee1b..d7c65b91 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_ME.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_ME.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sr_Latn_ME.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_RS@latin.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_RS@latin.php index 8ae8c41a..99716747 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_RS@latin.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_RS@latin.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss_ZA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss_ZA.php index 48d970ae..ba89527c 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss_ZA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss_ZA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/ss.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_AX.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_AX.php index 56425b4e..70cc5585 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_AX.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_AX.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sv.php', [ 'formats' => [ 'L' => 'YYYY-MM-dd', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_FI.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_FI.php index 1b73ecb2..d7182c83 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_FI.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_FI.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sv.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_SE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_SE.php index 1b73ecb2..d7182c83 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_SE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv_SE.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/sv.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_CD.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_CD.php index f6927f47..ec9117b5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_CD.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_CD.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sw.php', [ 'formats' => [ 'L' => 'DD/MM/YYYY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_UG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_UG.php index f6927f47..ec9117b5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_UG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sw_UG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/sw.php', [ 'formats' => [ 'L' => 'DD/MM/YYYY', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/szl_PL.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/szl_PL.php index 4b0b5410..9adddcf8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/szl_PL.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/szl_PL.php @@ -33,9 +33,9 @@ return array_replace_recursive(require __DIR__.'/en.php', [ 'm' => ':count mjeśůnc', 'a_month' => ':count mjeśůnc', - 'week' => ':count Tydźyń', - 'w' => ':count Tydźyń', - 'a_week' => ':count Tydźyń', + 'week' => ':count tydźyń', + 'w' => ':count tydźyń', + 'a_week' => ':count tydźyń', 'day' => ':count dźyń', 'd' => ':count dźyń', @@ -45,11 +45,11 @@ return array_replace_recursive(require __DIR__.'/en.php', [ 'h' => ':count godzina', 'a_hour' => ':count godzina', - 'minute' => ':count Minuta', - 'min' => ':count Minuta', - 'a_minute' => ':count Minuta', + 'minute' => ':count minuta', + 'min' => ':count minuta', + 'a_minute' => ':count minuta', - 'second' => ':count Sekůnda', - 's' => ':count Sekůnda', - 'a_second' => ':count Sekůnda', + 'second' => ':count sekůnda', + 's' => ':count sekůnda', + 'a_second' => ':count sekůnda', ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_MY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_MY.php index 291d6c81..a6cd8b51 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_MY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_MY.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ta.php', [ 'formats' => [ 'LT' => 'a h:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_SG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_SG.php index fe1cc062..7dbedeee 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_SG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ta_SG.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ta.php', [ 'formats' => [ 'LT' => 'a h:mm', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/te_IN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/te_IN.php index 6f81c405..3963f8d5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/te_IN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/te_IN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/te.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo.php index 950235ea..ca30c37d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ta.php', [ 'meridiem' => ['Taparachu', 'Ebongi'], 'weekdays' => ['Nakaejuma', 'Nakaebarasa', 'Nakaare', 'Nakauni', 'Nakaung’on', 'Nakakany', 'Nakasabiti'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo_KE.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo_KE.php index 024d2729..010a04f5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo_KE.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/teo_KE.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/teo.php', [ 'first_day_of_week' => 0, ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tg_TJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tg_TJ.php index c6591e34..badc7d1f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tg_TJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tg_TJ.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/tg.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/th_TH.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/th_TH.php index f11dc1b6..b9f94b2d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/th_TH.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/th_TH.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/th.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_CY.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_CY.php index 1937fec9..23f11449 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_CY.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_CY.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/tr.php', [ 'weekdays_short' => ['Paz', 'Pzt', 'Sal', 'Çar', 'Per', 'Cum', 'Cmt'], 'weekdays_min' => ['Pa', 'Pt', 'Sa', 'Ça', 'Pe', 'Cu', 'Ct'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_TR.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_TR.php index dc8e9358..9e994824 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_TR.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/tr_TR.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/tr.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/twq.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/twq.php index e8ff278c..5cbb46e0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/twq.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/twq.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/ses.php', [ 'meridiem' => ['Subbaahi', 'Zaarikay b'], ]); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php index ab2d8678..b267b000 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php @@ -8,7 +8,10 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -$processHoursFunction = function (\Carbon\CarbonInterface $date, string $format) { + +use Carbon\CarbonInterface; + +$processHoursFunction = function (CarbonInterface $date, string $format) { return $format.'о'.($date->hour === 11 ? 'б' : '').'] LT'; }; @@ -127,19 +130,19 @@ return [ 'LLLL' => 'dddd, D MMMM YYYY, HH:mm', ], 'calendar' => [ - 'sameDay' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) { + 'sameDay' => function (CarbonInterface $date) use ($processHoursFunction) { return $processHoursFunction($date, '[Сьогодні '); }, - 'nextDay' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) { + 'nextDay' => function (CarbonInterface $date) use ($processHoursFunction) { return $processHoursFunction($date, '[Завтра '); }, - 'nextWeek' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) { + 'nextWeek' => function (CarbonInterface $date) use ($processHoursFunction) { return $processHoursFunction($date, '[У] dddd ['); }, - 'lastDay' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) { + 'lastDay' => function (CarbonInterface $date) use ($processHoursFunction) { return $processHoursFunction($date, '[Вчора '); }, - 'lastWeek' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) { + 'lastWeek' => function (CarbonInterface $date) use ($processHoursFunction) { switch ($date->dayOfWeek) { case 0: case 3: @@ -183,17 +186,17 @@ return [ 'months_standalone' => ['січень', 'лютий', 'березень', 'квітень', 'травень', 'червень', 'липень', 'серпень', 'вересень', 'жовтень', 'листопад', 'грудень'], 'months_short' => ['січ', 'лют', 'бер', 'кві', 'тра', 'чер', 'лип', 'сер', 'вер', 'жов', 'лис', 'гру'], 'months_regexp' => '/(D[oD]?(\[[^\[\]]*\]|\s)+MMMM?|L{2,4}|l{2,4})/', - 'weekdays' => function (\Carbon\CarbonInterface $date, $format, $index) { + 'weekdays' => function (CarbonInterface $date, $format, $index) { static $words = [ 'nominative' => ['неділя', 'понеділок', 'вівторок', 'середа', 'четвер', 'п’ятниця', 'субота'], 'accusative' => ['неділю', 'понеділок', 'вівторок', 'середу', 'четвер', 'п’ятницю', 'суботу'], 'genitive' => ['неділі', 'понеділка', 'вівторка', 'середи', 'четверга', 'п’ятниці', 'суботи'], ]; - $nounCase = preg_match('/(\[(В|в|У|у)\])\s+dddd/', $format) + $nounCase = preg_match('/(\[(В|в|У|у)\])\s+dddd/u', $format) ? 'accusative' : ( - preg_match('/\[?(?:минулої|наступної)?\s*\]\s+dddd/', $format) + preg_match('/\[?(?:минулої|наступної)?\s*\]\s+dddd/u', $format) ? 'genitive' : 'nominative' ); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk_UA.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk_UA.php index 5fc43171..bd11d86e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk_UA.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk_UA.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/uk.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ur.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ur.php index e55aff28..dc16c2c3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ur.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ur.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + $months = [ 'جنوری', 'فروری', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Arab.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Arab.php index 68719114..ffb51319 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Arab.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Arab.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/fa.php', [ 'weekdays' => ['یکشنبه', 'دوشنبه', 'سه‌شنبه', 'چهارشنبه', 'پنجشنبه', 'جمعه', 'شنبه'], 'weekdays_short' => ['ی.', 'د.', 'س.', 'چ.', 'پ.', 'ج.', 'ش.'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Cyrl.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Cyrl.php index e8754699..89e99718 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Cyrl.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uz_Cyrl.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/uz.php', [ 'formats' => [ 'L' => 'DD/MM/yy', diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai.php index 3e6fce2b..3c378dfb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['ꕞꕌꔵ', 'ꗳꗡꘉ', 'ꕚꕞꕚ', 'ꕉꕞꕒ', 'ꕉꔤꕆꕢ', 'ꕉꔤꕀꕮ', 'ꔻꔬꔳ'], 'weekdays_short' => ['ꕞꕌꔵ', 'ꗳꗡꘉ', 'ꕚꕞꕚ', 'ꕉꕞꕒ', 'ꕉꔤꕆꕢ', 'ꕉꔤꕀꕮ', 'ꔻꔬꔳ'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Latn.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Latn.php index b76c4bcf..51e83cc5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Latn.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Latn.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'weekdays' => ['lahadi', 'tɛɛnɛɛ', 'talata', 'alaba', 'aimisa', 'aijima', 'siɓiti'], 'weekdays_short' => ['lahadi', 'tɛɛnɛɛ', 'talata', 'alaba', 'aimisa', 'aijima', 'siɓiti'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Vaii.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Vaii.php index 7b029a8a..b4bb533f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Vaii.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vai_Vaii.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/vai.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vi_VN.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vi_VN.php index 77b2dce5..18d89876 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vi_VN.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vi_VN.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/vi.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vo.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vo.php index a956a783..e273033f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vo.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vo.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'months' => ['M01', 'M02', 'M03', 'M04', 'M05', 'M06', 'M07', 'M08', 'M09', 'M10', 'M11', 'M12'], 'months_short' => ['M01', 'M02', 'M03', 'M04', 'M05', 'M06', 'M07', 'M08', 'M09', 'M10', 'M11', 'M12'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vun.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vun.php index f8cc72c1..ed92e8e7 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vun.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/vun.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['utuko', 'kyiukonyi'], 'weekdays' => ['Jumapilyi', 'Jumatatuu', 'Jumanne', 'Jumatanu', 'Alhamisi', 'Ijumaa', 'Jumamosi'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/xog.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/xog.php index 063977c0..eb55b4ab 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/xog.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/xog.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['Munkyo', 'Eigulo'], 'weekdays' => ['Sabiiti', 'Balaza', 'Owokubili', 'Owokusatu', 'Olokuna', 'Olokutaanu', 'Olomukaaga'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yav.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yav.php index e44cde62..225a20d8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yav.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yav.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/en.php', [ 'meridiem' => ['kiɛmɛ́ɛm', 'kisɛ́ndɛ'], 'weekdays' => ['sɔ́ndiɛ', 'móndie', 'muányáŋmóndie', 'metúkpíápɛ', 'kúpélimetúkpiapɛ', 'feléte', 'séselé'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_BJ.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_BJ.php index f06bb99f..12b9e815 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_BJ.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_BJ.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return array_replace_recursive(require __DIR__.'/yo.php', [ 'meridiem' => ['Àárɔ̀', 'Ɔ̀sán'], 'weekdays' => ['Ɔjɔ́ Àìkú', 'Ɔjɔ́ Ajé', 'Ɔjɔ́ Ìsɛ́gun', 'Ɔjɔ́rú', 'Ɔjɔ́bɔ', 'Ɔjɔ́ Ɛtì', 'Ɔjɔ́ Àbámɛ́ta'], diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_NG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_NG.php index 92934bcb..6860bc1a 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_NG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yo_NG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/yo.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hans.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hans.php index 007d0716..db913caa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hans.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hans.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hans.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hant.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hant.php index 24797f96..e2526f13 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hant.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/yue_Hant.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hant.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_HK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_HK.php index 007d0716..db913caa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_HK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_HK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hans.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_MO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_MO.php index 007d0716..db913caa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_MO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_MO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hans.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_SG.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_SG.php index 007d0716..db913caa 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_SG.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hans_SG.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hans.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_HK.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_HK.php index 24797f96..e2526f13 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_HK.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_HK.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hant.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_MO.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_MO.php index 24797f96..e2526f13 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_MO.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_MO.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hant.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_TW.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_TW.php index 24797f96..e2526f13 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_TW.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/zh_Hant_TW.php @@ -8,4 +8,5 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + return require __DIR__.'/zh_Hant.php'; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Language.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Language.php index 37902854..1fb5bafd 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Language.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Language.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; use JsonSerializable; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php index d71c888b..8be0569e 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php @@ -1,5 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + namespace Carbon\Laravel; use Carbon\Carbon; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php new file mode 100644 index 00000000..fc6fd2a7 --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php @@ -0,0 +1,222 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon\PHPStan; + +use Closure; +use PHPStan\Reflection\Php\BuiltinMethodReflection; +use PHPStan\TrinaryLogic; +use ReflectionClass; +use ReflectionFunction; +use ReflectionMethod; +use ReflectionParameter; +use ReflectionType; +use stdClass; +use Throwable; + +abstract class AbstractMacro implements BuiltinMethodReflection +{ + /** + * The reflection function/method. + * + * @var ReflectionFunction|ReflectionMethod + */ + protected $reflectionFunction; + + /** + * The class name. + * + * @var class-string + */ + private $className; + + /** + * The method name. + * + * @var string + */ + private $methodName; + + /** + * The parameters. + * + * @var ReflectionParameter[] + */ + private $parameters; + + /** + * The is static. + * + * @var bool + */ + private $static = false; + + /** + * Macro constructor. + * + * @param string $className + * @phpstan-param class-string $className + * + * @param string $methodName + * @param callable $macro + */ + public function __construct(string $className, string $methodName, $macro) + { + $this->className = $className; + $this->methodName = $methodName; + $this->reflectionFunction = \is_array($macro) + ? new ReflectionMethod($macro[0], $macro[1]) + : new ReflectionFunction($macro); + $this->parameters = $this->reflectionFunction->getParameters(); + + if ($this->reflectionFunction->isClosure()) { + try { + $closure = $this->reflectionFunction->getClosure(); + $boundClosure = Closure::bind($closure, new stdClass()); + $this->static = (!$boundClosure || (new ReflectionFunction($boundClosure))->getClosureThis() === null); + } catch (Throwable $e) { + $this->static = true; + } + } + } + + /** + * {@inheritdoc} + */ + public function getDeclaringClass(): ReflectionClass + { + return new ReflectionClass($this->className); + } + + /** + * {@inheritdoc} + */ + public function isPrivate(): bool + { + return false; + } + + /** + * {@inheritdoc} + */ + public function isPublic(): bool + { + return true; + } + + /** + * {@inheritdoc} + */ + public function isFinal(): bool + { + return false; + } + + /** + * {@inheritdoc} + */ + public function isInternal(): bool + { + return false; + } + + /** + * {@inheritdoc} + */ + public function isAbstract(): bool + { + return false; + } + + /** + * {@inheritdoc} + */ + public function isStatic(): bool + { + return $this->static; + } + + /** + * {@inheritdoc} + */ + public function getDocComment(): ?string + { + return $this->reflectionFunction->getDocComment() ?: null; + } + + /** + * {@inheritdoc} + */ + public function getName(): string + { + return $this->methodName; + } + + /** + * {@inheritdoc} + */ + public function getParameters(): array + { + return $this->parameters; + } + + /** + * {@inheritdoc} + */ + public function getReturnType(): ?ReflectionType + { + return $this->reflectionFunction->getReturnType(); + } + + /** + * {@inheritdoc} + */ + public function isDeprecated(): TrinaryLogic + { + return TrinaryLogic::createFromBoolean( + $this->reflectionFunction->isDeprecated() || + preg_match('/@deprecated/i', $this->getDocComment() ?: '') + ); + } + + /** + * {@inheritdoc} + */ + public function isVariadic(): bool + { + return $this->reflectionFunction->isVariadic(); + } + + /** + * {@inheritdoc} + */ + public function getPrototype(): BuiltinMethodReflection + { + return $this; + } + + /** + * {@inheritdoc} + */ + public function getReflection(): ?ReflectionMethod + { + return $this->reflectionFunction instanceof ReflectionMethod + ? $this->reflectionFunction + : null; + } + + public function getTentativeReturnType(): ?ReflectionType + { + return null; + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php index 7dab190c..83925873 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php @@ -2,232 +2,26 @@ declare(strict_types=1); +/** + * This file is part of the Carbon package. + * + * (c) Brian Nesbitt + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + namespace Carbon\PHPStan; -use Closure; use PHPStan\Reflection\Php\BuiltinMethodReflection; -use PHPStan\TrinaryLogic; -use ReflectionClass; -use ReflectionFunction; use ReflectionMethod; -use ReflectionParameter; -use ReflectionType; -use stdClass; -use Throwable; -final class Macro implements BuiltinMethodReflection +$method = new ReflectionMethod(BuiltinMethodReflection::class, 'getFileName'); + +require $method->hasReturnType() + ? __DIR__.'/../../../lazy/Carbon/PHPStan/MacroStrongType.php' + : __DIR__.'/../../../lazy/Carbon/PHPStan/MacroWeakType.php'; + +final class Macro extends LazyMacro { - /** - * The class name. - * - * @var class-string - */ - private $className; - - /** - * The method name. - * - * @var string - */ - private $methodName; - - /** - * The reflection function/method. - * - * @var ReflectionFunction|ReflectionMethod - */ - private $reflectionFunction; - - /** - * The parameters. - * - * @var ReflectionParameter[] - */ - private $parameters; - - /** - * The is static. - * - * @var bool - */ - private $static = false; - - /** - * Macro constructor. - * - * @param string $className - * @phpstan-param class-string $className - * - * @param string $methodName - * @param callable $macro - */ - public function __construct(string $className, string $methodName, $macro) - { - $this->className = $className; - $this->methodName = $methodName; - $this->reflectionFunction = \is_array($macro) - ? new ReflectionMethod($macro[0], $macro[1]) - : new ReflectionFunction($macro); - $this->parameters = $this->reflectionFunction->getParameters(); - - if ($this->reflectionFunction->isClosure()) { - try { - /** @var Closure $closure */ - $closure = $this->reflectionFunction->getClosure(); - $boundClosure = Closure::bind($closure, new stdClass); - $this->static = (!$boundClosure || (new ReflectionFunction($boundClosure))->getClosureThis() === null); - } catch (Throwable $e) { - $this->static = true; - } - } - } - - /** - * {@inheritdoc} - */ - public function getDeclaringClass(): ReflectionClass - { - return new ReflectionClass($this->className); - } - - /** - * {@inheritdoc} - */ - public function isPrivate(): bool - { - return false; - } - - /** - * {@inheritdoc} - */ - public function isPublic(): bool - { - return true; - } - - /** - * {@inheritdoc} - */ - public function isFinal(): bool - { - return false; - } - - /** - * {@inheritdoc} - */ - public function isInternal(): bool - { - return false; - } - - /** - * {@inheritdoc} - */ - public function isAbstract(): bool - { - return false; - } - - /** - * {@inheritdoc} - */ - public function isStatic(): bool - { - return $this->static; - } - - /** - * {@inheritdoc} - */ - public function getDocComment(): ?string - { - return $this->reflectionFunction->getDocComment() ?: null; - } - - /** - * {@inheritdoc} - */ - public function getFileName() - { - return $this->reflectionFunction->getFileName(); - } - - /** - * {@inheritdoc} - */ - public function getName(): string - { - return $this->methodName; - } - - /** - * {@inheritdoc} - */ - public function getParameters(): array - { - return $this->parameters; - } - - /** - * {@inheritdoc} - */ - public function getReturnType(): ?ReflectionType - { - return $this->reflectionFunction->getReturnType(); - } - - /** - * {@inheritdoc} - */ - public function getStartLine() - { - return $this->reflectionFunction->getStartLine(); - } - - /** - * {@inheritdoc} - */ - public function getEndLine() - { - return $this->reflectionFunction->getEndLine(); - } - - /** - * {@inheritdoc} - */ - public function isDeprecated(): TrinaryLogic - { - return TrinaryLogic::createFromBoolean( - $this->reflectionFunction->isDeprecated() || - preg_match('/@deprecated/i', $this->getDocComment() ?: '') - ); - } - - /** - * {@inheritdoc} - */ - public function isVariadic(): bool - { - return $this->reflectionFunction->isVariadic(); - } - - /** - * {@inheritdoc} - */ - public function getPrototype(): BuiltinMethodReflection - { - return $this; - } - - /** - * {@inheritdoc} - */ - public function getReflection(): ?ReflectionMethod - { - return $this->reflectionFunction instanceof ReflectionMethod - ? $this->reflectionFunction - : null; - } } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php index 5a3d6941..8e2524c0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php @@ -1,5 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + namespace Carbon\PHPStan; use PHPStan\Reflection\ClassReflection; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php index 97cf0b8e..d169939d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php @@ -1,5 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + namespace Carbon\PHPStan; use Carbon\CarbonInterface; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Boundaries.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Boundaries.php index 7fbb1a3f..71bbb723 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Boundaries.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Boundaries.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Exceptions\UnknownUnitException; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Cast.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Cast.php index 44caf0b3..5f7c7c01 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Cast.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Cast.php @@ -1,5 +1,14 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + namespace Carbon\Traits; use Carbon\Exceptions\InvalidCastException; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php index ee00666c..a23e6ed0 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use BadMethodCallException; @@ -74,7 +75,7 @@ trait Comparison */ public function equalTo($date): bool { - return $this == $date; + return $this == $this->resolveCarbon($date); } /** @@ -154,7 +155,7 @@ trait Comparison */ public function greaterThan($date): bool { - return $this > $date; + return $this > $this->resolveCarbon($date); } /** @@ -255,7 +256,7 @@ trait Comparison */ public function lessThan($date): bool { - return $this < $date; + return $this < $this->resolveCarbon($date); } /** diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php index 7ba62256..8fe008a5 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Carbon; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php index fa7cfc7b..f2adee5f 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Carbon; @@ -94,7 +95,7 @@ trait Creator setlocale(LC_NUMERIC, $locale); } - static::setLastErrors(parent::getLastErrors()); + self::setLastErrors(parent::getLastErrors()); } /** @@ -338,7 +339,7 @@ trait Creator return $now(static::now($tz)); } - return $now; + return $now->avoidMutation()->tz($tz); } /** @@ -367,7 +368,7 @@ trait Creator */ public static function create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null) { - if (\is_string($year) && !is_numeric($year)) { + if (\is_string($year) && !is_numeric($year) || $year instanceof DateTimeInterface) { return static::parse($year, $tz ?: (\is_string($month) || $month instanceof DateTimeZone ? $month : null)); } @@ -389,12 +390,12 @@ trait Creator return $defaults[$unit]; }; - $year = $year === null ? $getDefault('year') : $year; - $month = $month === null ? $getDefault('month') : $month; - $day = $day === null ? $getDefault('day') : $day; - $hour = $hour === null ? $getDefault('hour') : $hour; - $minute = $minute === null ? $getDefault('minute') : $minute; - $second = (float) ($second === null ? $getDefault('second') : $second); + $year = $year ?? $getDefault('year'); + $month = $month ?? $getDefault('month'); + $day = $day ?? $getDefault('day'); + $hour = $hour ?? $getDefault('hour'); + $minute = $minute ?? $getDefault('minute'); + $second = (float) ($second ?? $getDefault('second')); self::assertBetween('month', $month, 0, 99); self::assertBetween('day', $day, 0, 99); @@ -931,6 +932,8 @@ trait Creator /** * {@inheritdoc} + * + * @return array */ #[ReturnTypeWillChange] public static function getLastErrors() diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php index 07ac0dde..8c8af6fb 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use BadMethodCallException; @@ -38,6 +39,8 @@ use Throwable; /** * A simple API extension for DateTime. * + * @mixin DeprecatedProperties + * * * * @property int $year @@ -54,10 +57,6 @@ use Throwable; * @property string $shortEnglishDayOfWeek the abbreviated day of week in English * @property string $englishMonth the month in English * @property string $shortEnglishMonth the abbreviated month in English - * @property string $localeDayOfWeek the day of week in current locale LC_TIME - * @property string $shortLocaleDayOfWeek the abbreviated day of week in current locale LC_TIME - * @property string $localeMonth the month in current locale LC_TIME - * @property string $shortLocaleMonth the abbreviated month in current locale LC_TIME * @property int $milliseconds * @property int $millisecond * @property int $milli @@ -874,12 +873,28 @@ trait Date // @property string the abbreviated month in English 'shortEnglishMonth' => 'M', // @property string the day of week in current locale LC_TIME + // @deprecated + // reason: It uses OS language package and strftime() which is deprecated since PHP 8.1. + // replacement: Use ->isoFormat('MMM') instead. + // since: 2.55.0 'localeDayOfWeek' => '%A', // @property string the abbreviated day of week in current locale LC_TIME + // @deprecated + // reason: It uses OS language package and strftime() which is deprecated since PHP 8.1. + // replacement: Use ->isoFormat('dddd') instead. + // since: 2.55.0 'shortLocaleDayOfWeek' => '%a', // @property string the month in current locale LC_TIME + // @deprecated + // reason: It uses OS language package and strftime() which is deprecated since PHP 8.1. + // replacement: Use ->isoFormat('ddd') instead. + // since: 2.55.0 'localeMonth' => '%B', // @property string the abbreviated month in current locale LC_TIME + // @deprecated + // reason: It uses OS language package and strftime() which is deprecated since PHP 8.1. + // replacement: Use ->isoFormat('MMMM') instead. + // since: 2.55.0 'shortLocaleMonth' => '%b', // @property-read string $timezoneAbbreviatedName the current timezone abbreviated name 'timezoneAbbreviatedName' => 'T', @@ -1572,7 +1587,13 @@ trait Date #[ReturnTypeWillChange] public function setTimezone($value) { - return parent::setTimezone(static::safeCreateDateTimeZone($value)); + $tz = static::safeCreateDateTimeZone($value); + + if ($tz === false && !self::isStrictModeEnabled()) { + $tz = new CarbonTimeZone(); + } + + return parent::setTimezone($tz); } /** @@ -1584,10 +1605,11 @@ trait Date */ public function shiftTimezone($value) { - $offset = $this->offset; - $date = $this->setTimezone($value); + $dateTimeString = $this->format('Y-m-d H:i:s.u'); - return $date->addRealMicroseconds(($offset - $date->offset) * static::MICROSECONDS_PER_SECOND); + return $this + ->setTimezone($value) + ->modify($dateTimeString); } /** @@ -1672,7 +1694,7 @@ trait Date public static function getWeekStartsAt() { if (static::$weekStartsAt === static::WEEK_DAY_AUTO) { - return static::getFirstDayOfWeek(); + return self::getFirstDayOfWeek(); } return static::$weekStartsAt; @@ -1703,7 +1725,7 @@ trait Date public static function getWeekEndsAt() { if (static::$weekStartsAt === static::WEEK_DAY_AUTO) { - return (int) (static::DAYS_PER_WEEK - 1 + static::getFirstDayOfWeek()) % static::DAYS_PER_WEEK; + return (int) (static::DAYS_PER_WEEK - 1 + self::getFirstDayOfWeek()) % static::DAYS_PER_WEEK; } return static::$weekEndsAt; @@ -1811,6 +1833,10 @@ trait Date * Format the instance with the current locale. You can set the current * locale using setlocale() https://php.net/setlocale. * + * @deprecated It uses OS language package and strftime() which is deprecated since PHP 8.1. + * Use ->isoFormat() instead. + * Deprecated since 2.55.0 + * * @param string $format * * @return string diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/DeprecatedProperties.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/DeprecatedProperties.php new file mode 100644 index 00000000..5acc6f5c --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/DeprecatedProperties.php @@ -0,0 +1,61 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon\Traits; + +trait DeprecatedProperties +{ + /** + * the day of week in current locale LC_TIME + * + * @var string + * + * @deprecated It uses OS language package and strftime() which is deprecated since PHP 8.1. + * Use ->isoFormat('MMM') instead. + * Deprecated since 2.55.0 + */ + public $localeDayOfWeek; + + /** + * the abbreviated day of week in current locale LC_TIME + * + * @var string + * + * @deprecated It uses OS language package and strftime() which is deprecated since PHP 8.1. + * Use ->isoFormat('dddd') instead. + * Deprecated since 2.55.0 + */ + public $shortLocaleDayOfWeek; + + /** + * the month in current locale LC_TIME + * + * @var string + * + * @deprecated It uses OS language package and strftime() which is deprecated since PHP 8.1. + * Use ->isoFormat('ddd') instead. + * Deprecated since 2.55.0 + */ + public $localeMonth; + + /** + * the abbreviated month in current locale LC_TIME + * + * @var string + * + * @deprecated It uses OS language package and strftime() which is deprecated since PHP 8.1. + * Use ->isoFormat('MMMM') instead. + * Deprecated since 2.55.0 + */ + public $shortLocaleMonth; +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php index b1cdd6e3..cce1d2c3 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Carbon; @@ -111,7 +112,8 @@ trait Difference /** * Get the difference as a DateInterval instance. - * Return relative interval (negative if + * Return relative interval (negative if $absolute flag is not set to true and the given date is before + * current one). * * @param \Carbon\CarbonInterface|\DateTimeInterface|string|null $date * @param bool $absolute Get the absolute of the difference @@ -123,8 +125,10 @@ trait Difference { $other = $this->resolveCarbon($date); - // Can be removed if https://github.com/derickr/timelib/pull/110 - // is merged + // Work-around for https://bugs.php.net/bug.php?id=81458 + // It was initially introduced for https://bugs.php.net/bug.php?id=80998 + // The very specific case of 80998 was fixed in PHP 8.1beta3, but it introduced 81458 + // So we still need to keep this for now // @codeCoverageIgnoreStart if (version_compare(PHP_VERSION, '8.1.0-dev', '>=') && $other->tz !== $this->tz) { $other = $other->avoidMutation()->tz($this->tz); @@ -136,7 +140,8 @@ trait Difference /** * Get the difference as a CarbonInterval instance. - * Return absolute interval (always positive) unless you pass false to the second argument. + * Return relative interval (negative if $absolute flag is not set to true and the given date is before + * current one). * * @param \Carbon\CarbonInterface|\DateTimeInterface|string|null $date * @param bool $absolute Get the absolute of the difference @@ -212,7 +217,7 @@ trait Difference */ public function diffInDays($date = null, $absolute = true) { - return (int) $this->diff($this->resolveCarbon($date), $absolute)->format('%r%a'); + return $this->getIntervalDayDiff($this->diff($this->resolveCarbon($date), $absolute)); } /** @@ -513,7 +518,7 @@ trait Difference return $hoursDiff / static::HOURS_PER_DAY; } - $daysDiff = (int) $interval->format('%r%a'); + $daysDiff = $this->getIntervalDayDiff($interval); return $daysDiff + fmod($hoursDiff, static::HOURS_PER_DAY) / static::HOURS_PER_DAY; } @@ -781,6 +786,10 @@ trait Difference * - 'short' entry (see below) * - 'parts' entry (see below) * - 'options' entry (see below) + * - 'skip' entry, list of units to skip (array of strings or a single string, + * ` it can be the unit name (singular or plural) or its shortcut + * ` (y, m, w, d, h, min, s, ms, µs). + * - 'aUnit' entry, prefer "an hour" over "1 hour" if true * - 'join' entry determines how to join multiple parts of the string * ` - if $join is a string, it's used as a joiner glue * ` - if $join is a callable/closure, it get the list of string and should return a string @@ -789,6 +798,8 @@ trait Difference * ` - if $join is true, it will be guessed from the locale ('list' translation file entry) * ` - if $join is missing, a space will be used as glue * - 'other' entry (see above) + * - 'minimumUnit' entry determines the smallest unit of time to display can be long or + * ` short form of the units, e.g. 'hour' or 'h' (default value: s) * if int passed, it add modifiers: * Possible values: * - CarbonInterface::DIFF_ABSOLUTE no modifiers @@ -815,7 +826,7 @@ trait Difference $syntax['syntax'] = $syntax['syntax'] ?? null; $intSyntax = &$syntax['syntax']; } - $intSyntax = (int) ($intSyntax === null ? static::DIFF_RELATIVE_AUTO : $intSyntax); + $intSyntax = (int) ($intSyntax ?? static::DIFF_RELATIVE_AUTO); $intSyntax = $intSyntax === static::DIFF_RELATIVE_AUTO && $other === null ? static::DIFF_RELATIVE_TO_NOW : $intSyntax; $parts = min(7, max(1, (int) $parts)); @@ -1138,4 +1149,21 @@ trait Difference return $this->isoFormat((string) $format); } + + private function getIntervalDayDiff(DateInterval $interval): int + { + $daysDiff = (int) $interval->format('%a'); + $sign = $interval->format('%r') === '-' ? -1 : 1; + + if (\is_int($interval->days) && + $interval->y === 0 && + $interval->m === 0 && + version_compare(PHP_VERSION, '8.1.0-dev', '<') && + abs($interval->d - $daysDiff) === 1 + ) { + $daysDiff = abs($interval->d); + } + + return $daysDiff * $sign; + } } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php index 6f6c9d1d..4cd66b67 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\CarbonInterval; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalStep.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalStep.php index 4882eef6..82d7c326 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalStep.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalStep.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Carbon; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php index 9162dc94..ddd2b4e9 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\CarbonInterface; @@ -15,6 +16,7 @@ use Carbon\Exceptions\InvalidTypeException; use Carbon\Exceptions\NotLocaleAwareException; use Carbon\Language; use Carbon\Translator; +use Carbon\TranslatorStrongTypeInterface; use Closure; use Symfony\Component\Translation\TranslatorBagInterface; use Symfony\Component\Translation\TranslatorInterface; @@ -181,7 +183,7 @@ trait Localization $locale = $translator->getLocale(); } - $result = $translator->getCatalogue($locale)->get($key); + $result = self::getFromCatalogue($translator, $translator->getCatalogue($locale), $key); return $result === $key ? $default : $result; } @@ -237,10 +239,11 @@ trait Localization /** * Translate using translation string or callback available. * - * @param string $key - * @param array $parameters - * @param string|int|float|null $number - * @param \Symfony\Component\Translation\TranslatorInterface $translator + * @param string $key + * @param array $parameters + * @param string|int|float|null $number + * @param \Symfony\Component\Translation\TranslatorInterface|null $translator + * @param bool $altNumbers * * @return string */ @@ -582,7 +585,9 @@ trait Localization } foreach (['ago', 'from_now', 'before', 'after'] as $key) { - if ($translator instanceof TranslatorBagInterface && $translator->getCatalogue($newLocale)->get($key) instanceof Closure) { + if ($translator instanceof TranslatorBagInterface && + self::getFromCatalogue($translator, $translator->getCatalogue($newLocale), $key) instanceof Closure + ) { continue; } @@ -735,6 +740,19 @@ trait Localization return $translator; } + /** + * @param mixed $translator + * @param \Symfony\Component\Translation\MessageCatalogueInterface $catalogue + * + * @return mixed + */ + private static function getFromCatalogue($translator, $catalogue, string $id, string $domain = 'messages') + { + return $translator instanceof TranslatorStrongTypeInterface + ? $translator->getFromCatalogue($catalogue, $id, $domain) // @codeCoverageIgnore + : $catalogue->get($id, $domain); + } + /** * Return the word cleaned from its translation codes. * @@ -774,7 +792,7 @@ trait Localization $parts = explode('|', $message); return $key === 'to' - ? static::cleanWordFromTranslationString(end($parts)) + ? self::cleanWordFromTranslationString(end($parts)) : '(?:'.implode('|', array_map([static::class, 'cleanWordFromTranslationString'], $parts)).')'; }, $keys); } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Macro.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Macro.php index d4135264..92b6c9d8 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Macro.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Macro.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; /** diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php index b9c868df..88b251df 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Closure; @@ -65,8 +66,8 @@ trait Mixin public static function mixin($mixin) { \is_string($mixin) && trait_exists($mixin) - ? static::loadMixinTrait($mixin) - : static::loadMixinClass($mixin); + ? self::loadMixinTrait($mixin) + : self::loadMixinClass($mixin); } /** @@ -114,7 +115,7 @@ trait Mixin } // in case of errors not converted into exceptions - $closure = $closure ?? $closureBase; + $closure = $closure ?: $closureBase; return $closure(...\func_get_args()); }); diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php index 2fd64264..164dbbd1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\CarbonInterface; @@ -429,6 +430,8 @@ trait Modifiers * Calls \DateTime::modify if mutable or \DateTimeImmutable::modify else. * * @see https://php.net/manual/en/datetime.modify.php + * + * @return static|false */ #[ReturnTypeWillChange] public function modify($modify) diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mutability.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mutability.php index 66eaa124..561c867d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mutability.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mutability.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Carbon; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ObjectInitialisation.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ObjectInitialisation.php index 252df3a5..c77a1024 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ObjectInitialisation.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ObjectInitialisation.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; trait ObjectInitialisation diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php index 0a49372c..0ddee8dd 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\CarbonInterface; @@ -385,6 +386,10 @@ trait Options $this->locale(...$locales); } + if (isset($settings['innerTimezone'])) { + return $this->setTimezone($settings['innerTimezone']); + } + if (isset($settings['timezone'])) { return $this->shiftTimezone($settings['timezone']); } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php index 03d3fe69..33062397 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\CarbonInterface; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php index a27e4e35..eebc69bd 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\Exceptions\InvalidFormatException; @@ -135,6 +136,8 @@ trait Serialization /** * Set locale if specified on unserialize() called. + * + * @return void */ #[ReturnTypeWillChange] public function __wakeup() diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php index d9989749..c86faa74 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php @@ -8,10 +8,16 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; +use Carbon\CarbonInterface; +use Carbon\CarbonTimeZone; use Closure; use DateTimeImmutable; +use DateTimeInterface; +use InvalidArgumentException; +use Throwable; trait Test { @@ -26,6 +32,13 @@ trait Test */ protected static $testNow; + /** + * The timezone to resto to when clearing the time mock. + * + * @var string|null + */ + protected static $testDefaultTimezone; + /** * Set a Carbon instance (real or mock) to be returned when a "now" * instance is created. The provided instance will be returned @@ -38,6 +51,9 @@ trait Test * Note the timezone parameter was left out of the examples above and * has no affect as the mock value will be returned regardless of its value. * + * Only the moment is mocked with setTestNow(), the timezone will still be the one passed + * as parameter of date_default_timezone_get() as a fallback (see setTestNowAndTimezone()). + * * To clear the test instance call this method using the default * parameter of null. * @@ -54,6 +70,50 @@ trait Test static::$testNow = \is_string($testNow) ? static::parse($testNow) : $testNow; } + /** + * Set a Carbon instance (real or mock) to be returned when a "now" + * instance is created. The provided instance will be returned + * specifically under the following conditions: + * - A call to the static now() method, ex. Carbon::now() + * - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null) + * - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now') + * - When a string containing the desired time is passed to Carbon::parse(). + * + * It will also align default timezone (e.g. call date_default_timezone_set()) with + * the second argument or if null, with the timezone of the given date object. + * + * To clear the test instance call this method using the default + * parameter of null. + * + * /!\ Use this method for unit tests only. + * + * @param Closure|static|string|false|null $testNow real or mock Carbon instance + */ + public static function setTestNowAndTimezone($testNow = null, $tz = null) + { + if ($testNow) { + self::$testDefaultTimezone = self::$testDefaultTimezone ?? date_default_timezone_get(); + } + + $useDateInstanceTimezone = $testNow instanceof DateTimeInterface; + + if ($useDateInstanceTimezone) { + self::setDefaultTimezone($testNow->getTimezone()->getName(), $testNow); + } + + static::setTestNow($testNow); + + if (!$useDateInstanceTimezone) { + $now = static::getMockedTestNow(\func_num_args() === 1 ? null : $tz); + $tzName = $now ? $now->tzName : null; + self::setDefaultTimezone($tzName ?? self::$testDefaultTimezone ?? 'UTC', $now); + } + + if (!$testNow) { + self::$testDefaultTimezone = null; + } + } + /** * Temporarily sets a static date to be used within the callback. * Using setTestNow to set the date, executing the callback, then @@ -61,8 +121,8 @@ trait Test * * /!\ Use this method for unit tests only. * - * @param Closure|static|string|false|null $testNow real or mock Carbon instance - * @param Closure|null $callback + * @param Closure|static|string|false|null $testNow real or mock Carbon instance + * @param Closure|null $callback * * @return mixed */ @@ -97,27 +157,6 @@ trait Test return static::getTestNow() !== null; } - /** - * Return the given timezone and set it to the test instance if not null. - * If null, get the timezone from the test instance and return it. - * - * @param string|\DateTimeZone $tz - * @param \Carbon\CarbonInterface $testInstance - * - * @return string|\DateTimeZone - */ - protected static function handleMockTimezone($tz, &$testInstance) - { - //shift the time according to the given time zone - if ($tz !== null && $tz !== static::getMockedTestNow($tz)->getTimezone()) { - $testInstance = $testInstance->setTimezone($tz); - - return $tz; - } - - return $testInstance->getTimezone(); - } - /** * Get the mocked date passed in setTestNow() and if it's a Closure, execute it. * @@ -138,20 +177,48 @@ trait Test } /* @var \Carbon\CarbonImmutable|\Carbon\Carbon|null $testNow */ - return $testNow; + return $testNow instanceof CarbonInterface + ? $testNow->avoidMutation()->tz($tz) + : $testNow; } - protected static function mockConstructorParameters(&$time, &$tz) + protected static function mockConstructorParameters(&$time, $tz) { /** @var \Carbon\CarbonImmutable|\Carbon\Carbon $testInstance */ $testInstance = clone static::getMockedTestNow($tz); - $tz = static::handleMockTimezone($tz, $testInstance); - if (static::hasRelativeKeywords($time)) { $testInstance = $testInstance->modify($time); } - $time = $testInstance instanceof self ? $testInstance->rawFormat(static::MOCK_DATETIME_FORMAT) : $testInstance->format(static::MOCK_DATETIME_FORMAT); + $time = $testInstance instanceof self + ? $testInstance->rawFormat(static::MOCK_DATETIME_FORMAT) + : $testInstance->format(static::MOCK_DATETIME_FORMAT); + } + + private static function setDefaultTimezone($timezone, DateTimeInterface $date = null) + { + $previous = null; + $success = false; + + try { + $success = date_default_timezone_set($timezone); + } catch (Throwable $exception) { + $previous = $exception; + } + + if (!$success) { + $suggestion = @CarbonTimeZone::create($timezone)->toRegionName($date); + + throw new InvalidArgumentException( + "Timezone ID '$timezone' is invalid". + ($suggestion && $suggestion !== $timezone ? ", did you mean '$suggestion'?" : '.')."\n". + "It must be one of the IDs from DateTimeZone::listIdentifiers(),\n". + 'For the record, hours/minutes offset are relevant only for a particular moment, '. + 'but not as a default timezone.', + 0, + $previous + ); + } } } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php index 35d45aa5..2cb5c48d 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; /** diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php index aec85ab2..2902a8b1 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; use Carbon\CarbonConverterInterface; @@ -201,21 +202,6 @@ trait Units $unit = CarbonInterval::make($unit); } - // Can be removed if https://bugs.php.net/bug.php?id=81106 - // is fixed - // @codeCoverageIgnoreStart - if ( - $unit instanceof DateInterval && - version_compare(PHP_VERSION, '8.1.0-dev', '>=') && - ($unit->f < 0 || $unit->f >= 1) - ) { - $unit = clone $unit; - $seconds = floor($unit->f); - $unit->f -= $seconds; - $unit->s += (int) $seconds; - } - // @codeCoverageIgnoreEnd - if ($unit instanceof CarbonConverterInterface) { return $this->resolveCarbon($unit->convertDate($this, false)); } @@ -252,6 +238,7 @@ trait Units return $date->isMutable() ? $date : $date->avoidMutation(); } + $unit = self::singularUnit($unit); $metaUnits = [ 'millennium' => [static::YEARS_PER_MILLENNIUM, 'year'], 'century' => [static::YEARS_PER_CENTURY, 'year'], @@ -320,11 +307,13 @@ trait Units $date = $date->modify("$value $unit"); if (isset($timeString)) { - return $date->setTimeFromTimeString($timeString); + $date = $date->setTimeFromTimeString($timeString); + } elseif (isset($canOverflow, $day) && $canOverflow && $day !== $date->day) { + $date = $date->modify('last day of previous month'); } - if (isset($canOverflow, $day) && $canOverflow && $day !== $date->day) { - $date = $date->modify('last day of previous month'); + if (!$date) { + throw new UnitException('Unable to add unit '.var_export(\func_get_args(), true)); } return $date; diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Week.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Week.php index 64cece7a..6f148145 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Week.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Week.php @@ -8,6 +8,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon\Traits; /** diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Translator.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Translator.php index 9af48ebe..491c9e72 100644 --- a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Translator.php +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Translator.php @@ -8,396 +8,25 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace Carbon; -use Closure; -use ReflectionException; -use ReflectionFunction; +use ReflectionMethod; use Symfony\Component\Translation; +use Symfony\Contracts\Translation\TranslatorInterface; -class Translator extends Translation\Translator +$transMethod = new ReflectionMethod( + class_exists(TranslatorInterface::class) + ? TranslatorInterface::class + : Translation\Translator::class, + 'trans' +); + +require $transMethod->hasReturnType() + ? __DIR__.'/../../lazy/Carbon/TranslatorStrongType.php' + : __DIR__.'/../../lazy/Carbon/TranslatorWeakType.php'; + +class Translator extends LazyTranslator { - /** - * Translator singletons for each language. - * - * @var array - */ - protected static $singletons = []; - - /** - * List of custom localized messages. - * - * @var array - */ - protected $messages = []; - - /** - * List of custom directories that contain translation files. - * - * @var string[] - */ - protected $directories = []; - - /** - * Set to true while constructing. - * - * @var bool - */ - protected $initializing = false; - - /** - * List of locales aliases. - * - * @var string[] - */ - protected $aliases = [ - 'me' => 'sr_Latn_ME', - 'scr' => 'sh', - ]; - - /** - * Return a singleton instance of Translator. - * - * @param string|null $locale optional initial locale ("en" - english by default) - * - * @return static - */ - public static function get($locale = null) - { - $locale = $locale ?: 'en'; - - if (!isset(static::$singletons[$locale])) { - static::$singletons[$locale] = new static($locale ?: 'en'); - } - - return static::$singletons[$locale]; - } - - public function __construct($locale, Translation\Formatter\MessageFormatterInterface $formatter = null, $cacheDir = null, $debug = false) - { - $this->initializing = true; - $this->directories = [__DIR__.'/Lang']; - $this->addLoader('array', new Translation\Loader\ArrayLoader()); - parent::__construct($locale, $formatter, $cacheDir, $debug); - $this->initializing = false; - } - - /** - * Returns the list of directories translation files are searched in. - * - * @return array - */ - public function getDirectories(): array - { - return $this->directories; - } - - /** - * Set list of directories translation files are searched in. - * - * @param array $directories new directories list - * - * @return $this - */ - public function setDirectories(array $directories) - { - $this->directories = $directories; - - return $this; - } - - /** - * Add a directory to the list translation files are searched in. - * - * @param string $directory new directory - * - * @return $this - */ - public function addDirectory(string $directory) - { - $this->directories[] = $directory; - - return $this; - } - - /** - * Remove a directory from the list translation files are searched in. - * - * @param string $directory directory path - * - * @return $this - */ - public function removeDirectory(string $directory) - { - $search = rtrim(strtr($directory, '\\', '/'), '/'); - - return $this->setDirectories(array_filter($this->getDirectories(), function ($item) use ($search) { - return rtrim(strtr($item, '\\', '/'), '/') !== $search; - })); - } - - /** - * Returns the translation. - * - * @param string $id - * @param array $parameters - * @param string $domain - * @param string $locale - * - * @return string - */ - public function trans($id, array $parameters = [], $domain = null, $locale = null) - { - if ($domain === null) { - $domain = 'messages'; - } - - $format = $this->getCatalogue($locale)->get((string) $id, $domain); - - if ($format instanceof Closure) { - // @codeCoverageIgnoreStart - try { - $count = (new ReflectionFunction($format))->getNumberOfRequiredParameters(); - } catch (ReflectionException $exception) { - $count = 0; - } - // @codeCoverageIgnoreEnd - - return $format( - ...array_values($parameters), - ...array_fill(0, max(0, $count - \count($parameters)), null) - ); - } - - return parent::trans($id, $parameters, $domain, $locale); - } - - /** - * Reset messages of a locale (all locale if no locale passed). - * Remove custom messages and reload initial messages from matching - * file in Lang directory. - * - * @param string|null $locale - * - * @return bool - */ - public function resetMessages($locale = null) - { - if ($locale === null) { - $this->messages = []; - - return true; - } - - foreach ($this->getDirectories() as $directory) { - $data = @include sprintf('%s/%s.php', rtrim($directory, '\\/'), $locale); - - if ($data !== false) { - $this->messages[$locale] = $data; - $this->addResource('array', $this->messages[$locale], $locale); - - return true; - } - } - - return false; - } - - /** - * Returns the list of files matching a given locale prefix (or all if empty). - * - * @param string $prefix prefix required to filter result - * - * @return array - */ - public function getLocalesFiles($prefix = '') - { - $files = []; - - foreach ($this->getDirectories() as $directory) { - $directory = rtrim($directory, '\\/'); - - foreach (glob("$directory/$prefix*.php") as $file) { - $files[] = $file; - } - } - - return array_unique($files); - } - - /** - * Returns the list of internally available locales and already loaded custom locales. - * (It will ignore custom translator dynamic loading.) - * - * @param string $prefix prefix required to filter result - * - * @return array - */ - public function getAvailableLocales($prefix = '') - { - $locales = []; - foreach ($this->getLocalesFiles($prefix) as $file) { - $locales[] = substr($file, strrpos($file, '/') + 1, -4); - } - - return array_unique(array_merge($locales, array_keys($this->messages))); - } - - /** - * Init messages language from matching file in Lang directory. - * - * @param string $locale - * - * @return bool - */ - protected function loadMessagesFromFile($locale) - { - if (isset($this->messages[$locale])) { - return true; - } - - return $this->resetMessages($locale); - } - - /** - * Set messages of a locale and take file first if present. - * - * @param string $locale - * @param array $messages - * - * @return $this - */ - public function setMessages($locale, $messages) - { - $this->loadMessagesFromFile($locale); - $this->addResource('array', $messages, $locale); - $this->messages[$locale] = array_merge( - isset($this->messages[$locale]) ? $this->messages[$locale] : [], - $messages - ); - - return $this; - } - - /** - * Set messages of the current locale and take file first if present. - * - * @param array $messages - * - * @return $this - */ - public function setTranslations($messages) - { - return $this->setMessages($this->getLocale(), $messages); - } - - /** - * Get messages of a locale, if none given, return all the - * languages. - * - * @param string|null $locale - * - * @return array - */ - public function getMessages($locale = null) - { - return $locale === null ? $this->messages : $this->messages[$locale]; - } - - /** - * Set the current translator locale and indicate if the source locale file exists - * - * @param string $locale locale ex. en - * - * @return bool - */ - public function setLocale($locale) - { - $locale = preg_replace_callback('/[-_]([a-z]{2,}|[0-9]{2,})/', function ($matches) { - // _2-letters or YUE is a region, _3+-letters is a variant - $upper = strtoupper($matches[1]); - - if ($upper === 'YUE' || $upper === 'ISO' || \strlen($upper) < 3) { - return "_$upper"; - } - - return '_'.ucfirst($matches[1]); - }, strtolower($locale)); - - $previousLocale = $this->getLocale(); - - if ($previousLocale === $locale && isset($this->messages[$locale])) { - return true; - } - - unset(static::$singletons[$previousLocale]); - - if ($locale === 'auto') { - $completeLocale = setlocale(LC_TIME, '0'); - $locale = preg_replace('/^([^_.-]+).*$/', '$1', $completeLocale); - $locales = $this->getAvailableLocales($locale); - - $completeLocaleChunks = preg_split('/[_.-]+/', $completeLocale); - - $getScore = function ($language) use ($completeLocaleChunks) { - return static::compareChunkLists($completeLocaleChunks, preg_split('/[_.-]+/', $language)); - }; - - usort($locales, function ($first, $second) use ($getScore) { - return $getScore($second) <=> $getScore($first); - }); - - $locale = $locales[0]; - } - - if (isset($this->aliases[$locale])) { - $locale = $this->aliases[$locale]; - } - - // If subtag (ex: en_CA) first load the macro (ex: en) to have a fallback - if (str_contains($locale, '_') && - $this->loadMessagesFromFile($macroLocale = preg_replace('/^([^_]+).*$/', '$1', $locale)) - ) { - parent::setLocale($macroLocale); - } - - if ($this->loadMessagesFromFile($locale) || $this->initializing) { - parent::setLocale($locale); - - return true; - } - - return false; - } - - /** - * Show locale on var_dump(). - * - * @return array - */ - public function __debugInfo() - { - return [ - 'locale' => $this->getLocale(), - ]; - } - - private static function compareChunkLists($referenceChunks, $chunks) - { - $score = 0; - - foreach ($referenceChunks as $index => $chunk) { - if (!isset($chunks[$index])) { - $score++; - - continue; - } - - if (strtolower($chunks[$index]) === strtolower($chunk)) { - $score += 10; - } - } - - return $score; - } + // Proxy dynamically loaded LazyTranslator in a static way } diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php new file mode 100644 index 00000000..ad36c670 --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php @@ -0,0 +1,99 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon; + +use Carbon\Exceptions\ImmutableException; +use Symfony\Component\Config\ConfigCacheFactoryInterface; +use Symfony\Component\Translation\Formatter\MessageFormatterInterface; + +class TranslatorImmutable extends Translator +{ + /** @var bool */ + private $constructed = false; + + public function __construct($locale, MessageFormatterInterface $formatter = null, $cacheDir = null, $debug = false) + { + parent::__construct($locale, $formatter, $cacheDir, $debug); + $this->constructed = true; + } + + /** + * @codeCoverageIgnore + */ + public function setDirectories(array $directories) + { + $this->disallowMutation(__METHOD__); + + return parent::setDirectories($directories); + } + + public function setLocale($locale) + { + $this->disallowMutation(__METHOD__); + + return parent::setLocale($locale); + } + + /** + * @codeCoverageIgnore + */ + public function setMessages($locale, $messages) + { + $this->disallowMutation(__METHOD__); + + return parent::setMessages($locale, $messages); + } + + /** + * @codeCoverageIgnore + */ + public function setTranslations($messages) + { + $this->disallowMutation(__METHOD__); + + return parent::setTranslations($messages); + } + + /** + * @codeCoverageIgnore + */ + public function setConfigCacheFactory(ConfigCacheFactoryInterface $configCacheFactory) + { + $this->disallowMutation(__METHOD__); + + parent::setConfigCacheFactory($configCacheFactory); + } + + public function resetMessages($locale = null) + { + $this->disallowMutation(__METHOD__); + + return parent::resetMessages($locale); + } + + /** + * @codeCoverageIgnore + */ + public function setFallbackLocales(array $locales) + { + $this->disallowMutation(__METHOD__); + + parent::setFallbackLocales($locales); + } + + private function disallowMutation($method) + { + if ($this->constructed) { + throw new ImmutableException($method.' not allowed on '.static::class); + } + } +} diff --git a/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorStrongTypeInterface.php b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorStrongTypeInterface.php new file mode 100644 index 00000000..ef4dee8e --- /dev/null +++ b/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorStrongTypeInterface.php @@ -0,0 +1,22 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Carbon; + +use Symfony\Component\Translation\MessageCatalogueInterface; + +/** + * Mark translator using strong type from symfony/translation >= 6. + */ +interface TranslatorStrongTypeInterface +{ + public function getFromCatalogue(MessageCatalogueInterface $catalogue, string $id, string $domain = 'messages'); +} diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/README.md b/data/web/inc/lib/vendor/phpmailer/phpmailer/README.md index fa27d2f6..81b08976 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/README.md +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/README.md @@ -2,7 +2,12 @@ # PHPMailer – A full-featured email creation and transfer class for PHP -[![Test status](https://github.com/PHPMailer/PHPMailer/workflows/Tests/badge.svg)](https://github.com/PHPMailer/PHPMailer/actions) [![Latest Stable Version](https://poser.pugx.org/phpmailer/phpmailer/v/stable.svg)](https://packagist.org/packages/phpmailer/phpmailer) [![Total Downloads](https://poser.pugx.org/phpmailer/phpmailer/downloads)](https://packagist.org/packages/phpmailer/phpmailer) [![License](https://poser.pugx.org/phpmailer/phpmailer/license.svg)](https://packagist.org/packages/phpmailer/phpmailer) [![API Docs](https://github.com/phpmailer/phpmailer/workflows/Docs/badge.svg)](https://phpmailer.github.io/PHPMailer/) +[![Test status](https://github.com/PHPMailer/PHPMailer/workflows/Tests/badge.svg)](https://github.com/PHPMailer/PHPMailer/actions) +[![codecov.io](https://codecov.io/gh/PHPMailer/PHPMailer/branch/master/graph/badge.svg?token=iORZpwmYmM)](https://codecov.io/gh/PHPMailer/PHPMailer) +[![Latest Stable Version](https://poser.pugx.org/phpmailer/phpmailer/v/stable.svg)](https://packagist.org/packages/phpmailer/phpmailer) +[![Total Downloads](https://poser.pugx.org/phpmailer/phpmailer/downloads)](https://packagist.org/packages/phpmailer/phpmailer) +[![License](https://poser.pugx.org/phpmailer/phpmailer/license.svg)](https://packagist.org/packages/phpmailer/phpmailer) +[![API Docs](https://github.com/phpmailer/phpmailer/workflows/Docs/badge.svg)](https://phpmailer.github.io/PHPMailer/) ## Features - Probably the world's most popular code for sending email from PHP! @@ -17,7 +22,7 @@ - Protects against header injection attacks - Error messages in over 50 languages! - DKIM and S/MIME signing support -- Compatible with PHP 5.5 and later, including PHP 8.0 +- Compatible with PHP 5.5 and later, including PHP 8.1 - Namespaced to prevent name clashes - Much more! @@ -39,7 +44,7 @@ This software is distributed under the [LGPL 2.1](http://www.gnu.org/licenses/lg PHPMailer is available on [Packagist](https://packagist.org/packages/phpmailer/phpmailer) (using semantic versioning), and installation via [Composer](https://getcomposer.org) is the recommended way to install PHPMailer. Just add this line to your `composer.json` file: ```json -"phpmailer/phpmailer": "^6.2" +"phpmailer/phpmailer": "^6.5" ``` or run @@ -89,7 +94,7 @@ use PHPMailer\PHPMailer\Exception; //Load Composer's autoloader require 'vendor/autoload.php'; -//Instantiation and passing `true` enables exceptions +//Create an instance; passing `true` enables exceptions $mail = new PHPMailer(true); try { @@ -100,8 +105,8 @@ try { $mail->SMTPAuth = true; //Enable SMTP authentication $mail->Username = 'user@example.com'; //SMTP username $mail->Password = 'secret'; //SMTP password - $mail->SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS; //Enable TLS encryption; `PHPMailer::ENCRYPTION_SMTPS` encouraged - $mail->Port = 587; //TCP port to connect to, use 465 for `PHPMailer::ENCRYPTION_SMTPS` above + $mail->SMTPSecure = PHPMailer::ENCRYPTION_SMTPS; //Enable implicit TLS encryption + $mail->Port = 465; //TCP port to connect to; use 587 if you have set `SMTPSecure = PHPMailer::ENCRYPTION_STARTTLS` //Recipients $mail->setFrom('from@example.com', 'Mailer'); diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/VERSION b/data/web/inc/lib/vendor/phpmailer/phpmailer/VERSION index 4be2c727..cd802a1e 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/VERSION +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/VERSION @@ -1 +1 @@ -6.5.0 \ No newline at end of file +6.6.0 \ No newline at end of file diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/composer.json b/data/web/inc/lib/vendor/phpmailer/phpmailer/composer.json index 58393b2c..b13732be 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/composer.json +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/composer.json @@ -25,6 +25,11 @@ "type": "github" } ], + "config": { + "allow-plugins": { + "dealerdirect/phpcodesniffer-composer-installer": true + } + }, "require": { "php": ">=5.5.0", "ext-ctype": "*", @@ -34,10 +39,12 @@ "require-dev": { "dealerdirect/phpcodesniffer-composer-installer": "^0.7.0", "doctrine/annotations": "^1.2", + "php-parallel-lint/php-console-highlighter": "^0.5.0", + "php-parallel-lint/php-parallel-lint": "^1.3.1", "phpcompatibility/php-compatibility": "^9.3.5", "roave/security-advisories": "dev-latest", - "squizlabs/php_codesniffer": "^3.5.6", - "yoast/phpunit-polyfills": "^0.2.0" + "squizlabs/php_codesniffer": "^3.6.2", + "yoast/phpunit-polyfills": "^1.0.0" }, "suggest": { "ext-mbstring": "Needed to send email in multibyte encoding charset or decode encoded addresses", @@ -60,6 +67,10 @@ "license": "LGPL-2.1-only", "scripts": { "check": "./vendor/bin/phpcs", - "test": "./vendor/bin/phpunit" + "test": "./vendor/bin/phpunit --no-coverage", + "coverage": "./vendor/bin/phpunit", + "lint": [ + "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php,phps --exclude vendor --exclude .git --exclude build" + ] } } diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-fr.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-fr.php index b57f0ec6..38a7a8e7 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-fr.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-fr.php @@ -9,24 +9,30 @@ * @see http://unicode.org/udhr/n/notes_fra.html */ -$PHPMAILER_LANG['authenticate'] = 'Erreur SMTP : échec de l\'authentification.'; +$PHPMAILER_LANG['authenticate'] = 'Erreur SMTP : échec de l’authentification.'; +$PHPMAILER_LANG['buggy_php'] = 'Votre version de PHP est affectée par un bug qui peut entraîner des messages corrompus. Pour résoudre ce problème, passez à l’envoi par SMTP, désactivez l’option mail.add_x_header dans le fichier php.ini, passez à MacOS ou Linux, ou passez PHP à la version 7.0.17+ ou 7.1.3+.'; $PHPMAILER_LANG['connect_host'] = 'Erreur SMTP : impossible de se connecter au serveur SMTP.'; $PHPMAILER_LANG['data_not_accepted'] = 'Erreur SMTP : données incorrectes.'; $PHPMAILER_LANG['empty_message'] = 'Corps du message vide.'; $PHPMAILER_LANG['encoding'] = 'Encodage inconnu : '; -$PHPMAILER_LANG['execute'] = 'Impossible de lancer l\'exécution : '; -$PHPMAILER_LANG['file_access'] = 'Impossible d\'accéder au fichier : '; +$PHPMAILER_LANG['execute'] = 'Impossible de lancer l’exécution : '; +$PHPMAILER_LANG['extension_missing'] = 'Extension manquante : '; +$PHPMAILER_LANG['file_access'] = 'Impossible d’accéder au fichier : '; $PHPMAILER_LANG['file_open'] = 'Ouverture du fichier impossible : '; -$PHPMAILER_LANG['from_failed'] = 'L\'adresse d\'expéditeur suivante a échoué : '; -$PHPMAILER_LANG['instantiate'] = 'Impossible d\'instancier la fonction mail.'; -$PHPMAILER_LANG['invalid_address'] = 'L\'adresse courriel n\'est pas valide : '; -$PHPMAILER_LANG['invalid_hostentry'] = 'L\'entrée hôte n\'est pas valide : '; -$PHPMAILER_LANG['invalid_host'] = 'L\'hôte n\'est pas valide : '; +$PHPMAILER_LANG['from_failed'] = 'L’adresse d’expéditeur suivante a échoué : '; +$PHPMAILER_LANG['instantiate'] = 'Impossible d’instancier la fonction mail.'; +$PHPMAILER_LANG['invalid_address'] = 'Adresse courriel non valide : '; +$PHPMAILER_LANG['invalid_header'] = 'Nom ou valeur de l’en-tête non valide'; +$PHPMAILER_LANG['invalid_hostentry'] = 'Entrée d’hôte non valide : '; +$PHPMAILER_LANG['invalid_host'] = 'Hôte non valide : '; $PHPMAILER_LANG['mailer_not_supported'] = ' client de messagerie non supporté.'; $PHPMAILER_LANG['provide_address'] = 'Vous devez fournir au moins une adresse de destinataire.'; -$PHPMAILER_LANG['recipients_failed'] = 'Erreur SMTP : les destinataires suivants sont en erreur : '; +$PHPMAILER_LANG['recipients_failed'] = 'Erreur SMTP : les destinataires suivants ont échoué : '; $PHPMAILER_LANG['signing'] = 'Erreur de signature : '; -$PHPMAILER_LANG['smtp_connect_failed'] = 'Échec de la connexion SMTP.'; +$PHPMAILER_LANG['smtp_code'] = 'Code SMTP : '; +$PHPMAILER_LANG['smtp_code_ex'] = 'Informations supplémentaires SMTP : '; +$PHPMAILER_LANG['smtp_connect_failed'] = 'La fonction SMTP connect() a échouée.'; +$PHPMAILER_LANG['smtp_detail'] = 'Détails : '; $PHPMAILER_LANG['smtp_error'] = 'Erreur du serveur SMTP : '; -$PHPMAILER_LANG['variable_set'] = 'Impossible d\'initialiser ou de réinitialiser une variable : '; +$PHPMAILER_LANG['variable_set'] = 'Impossible d’initialiser ou de réinitialiser une variable : '; $PHPMAILER_LANG['extension_missing'] = 'Extension manquante : '; diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ja.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ja.php index eee79898..c76f5264 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ja.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ja.php @@ -5,24 +5,25 @@ * @package PHPMailer * @author Mitsuhiro Yoshida * @author Yoshi Sakai + * @author Arisophy */ $PHPMAILER_LANG['authenticate'] = 'SMTPエラー: 認証できませんでした。'; $PHPMAILER_LANG['connect_host'] = 'SMTPエラー: SMTPホストに接続できませんでした。'; $PHPMAILER_LANG['data_not_accepted'] = 'SMTPエラー: データが受け付けられませんでした。'; -//$PHPMAILER_LANG['empty_message'] = 'Message body empty'; +$PHPMAILER_LANG['empty_message'] = 'メール本文が空です。'; $PHPMAILER_LANG['encoding'] = '不明なエンコーディング: '; $PHPMAILER_LANG['execute'] = '実行できませんでした: '; $PHPMAILER_LANG['file_access'] = 'ファイルにアクセスできません: '; $PHPMAILER_LANG['file_open'] = 'ファイルエラー: ファイルを開けません: '; $PHPMAILER_LANG['from_failed'] = 'Fromアドレスを登録する際にエラーが発生しました: '; $PHPMAILER_LANG['instantiate'] = 'メール関数が正常に動作しませんでした。'; -//$PHPMAILER_LANG['invalid_address'] = 'Invalid address: '; +$PHPMAILER_LANG['invalid_address'] = '不正なメールアドレス: '; $PHPMAILER_LANG['provide_address'] = '少なくとも1つメールアドレスを 指定する必要があります。'; $PHPMAILER_LANG['mailer_not_supported'] = ' メーラーがサポートされていません。'; $PHPMAILER_LANG['recipients_failed'] = 'SMTPエラー: 次の受信者アドレスに 間違いがあります: '; -//$PHPMAILER_LANG['signing'] = 'Signing Error: '; -//$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Connect() failed.'; -//$PHPMAILER_LANG['smtp_error'] = 'SMTP server error: '; -//$PHPMAILER_LANG['variable_set'] = 'Cannot set or reset variable: '; -//$PHPMAILER_LANG['extension_missing'] = 'Extension missing: '; +$PHPMAILER_LANG['signing'] = '署名エラー: '; +$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP接続に失敗しました。'; +$PHPMAILER_LANG['smtp_error'] = 'SMTPサーバーエラー: '; +$PHPMAILER_LANG['variable_set'] = '変数が存在しません: '; +$PHPMAILER_LANG['extension_missing'] = '拡張機能が見つかりません: '; diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-nl.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-nl.php index bf41ade8..8229d5e2 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-nl.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-nl.php @@ -7,23 +7,28 @@ */ $PHPMAILER_LANG['authenticate'] = 'SMTP-fout: authenticatie mislukt.'; +$PHPMAILER_LANG['buggy_php'] = 'PHP versie gededecteerd die onderhavig is aan een bug die kan resulteren in gecorrumpeerde berichten. Om dit te voorkomen, gebruik SMTP voor het verzenden van berichten, zet de mail.add_x_header optie in uw php.ini file uit, gebruik MacOS of Linux, of pas de gebruikte PHP versie aan naar versie 7.0.17+ or 7.1.3+.'; $PHPMAILER_LANG['connect_host'] = 'SMTP-fout: kon niet verbinden met SMTP-host.'; $PHPMAILER_LANG['data_not_accepted'] = 'SMTP-fout: data niet geaccepteerd.'; $PHPMAILER_LANG['empty_message'] = 'Berichttekst is leeg'; $PHPMAILER_LANG['encoding'] = 'Onbekende codering: '; $PHPMAILER_LANG['execute'] = 'Kon niet uitvoeren: '; +$PHPMAILER_LANG['extension_missing'] = 'Extensie afwezig: '; $PHPMAILER_LANG['file_access'] = 'Kreeg geen toegang tot bestand: '; $PHPMAILER_LANG['file_open'] = 'Bestandsfout: kon bestand niet openen: '; $PHPMAILER_LANG['from_failed'] = 'Het volgende afzendersadres is mislukt: '; $PHPMAILER_LANG['instantiate'] = 'Kon mailfunctie niet initialiseren.'; $PHPMAILER_LANG['invalid_address'] = 'Ongeldig adres: '; +$PHPMAILER_LANG['invalid_header'] = 'Ongeldige header naam of waarde'; $PHPMAILER_LANG['invalid_hostentry'] = 'Ongeldige hostentry: '; $PHPMAILER_LANG['invalid_host'] = 'Ongeldige host: '; $PHPMAILER_LANG['mailer_not_supported'] = ' mailer wordt niet ondersteund.'; $PHPMAILER_LANG['provide_address'] = 'Er moet minstens één ontvanger worden opgegeven.'; $PHPMAILER_LANG['recipients_failed'] = 'SMTP-fout: de volgende ontvangers zijn mislukt: '; $PHPMAILER_LANG['signing'] = 'Signeerfout: '; +$PHPMAILER_LANG['smtp_code'] = 'SMTP code: '; +$PHPMAILER_LANG['smtp_code_ex'] = 'Aanvullende SMTP informatie: '; $PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Verbinding mislukt.'; +$PHPMAILER_LANG['smtp_detail'] = 'Detail: '; $PHPMAILER_LANG['smtp_error'] = 'SMTP-serverfout: '; $PHPMAILER_LANG['variable_set'] = 'Kan de volgende variabele niet instellen of resetten: '; -$PHPMAILER_LANG['extension_missing'] = 'Extensie afwezig: '; diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-pt_br.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-pt_br.php index d8638098..5239865a 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-pt_br.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-pt_br.php @@ -7,24 +7,32 @@ * @author Lucas Guimarães * @author Phelipe Alves * @author Fabio Beneditto + * @author Geidson Benício Coelho */ $PHPMAILER_LANG['authenticate'] = 'Erro de SMTP: Não foi possível autenticar.'; +$PHPMAILER_LANG['buggy_php'] = 'Sua versão do PHP é afetada por um bug que por resultar em messagens corrompidas. Para corrigir, mude para enviar usando SMTP, desative a opção mail.add_x_header em seu php.ini, mude para MacOS ou Linux, ou atualize seu PHP para versão 7.0.17+ ou 7.1.3+ '; $PHPMAILER_LANG['connect_host'] = 'Erro de SMTP: Não foi possível conectar ao servidor SMTP.'; $PHPMAILER_LANG['data_not_accepted'] = 'Erro de SMTP: Dados rejeitados.'; $PHPMAILER_LANG['empty_message'] = 'Mensagem vazia'; $PHPMAILER_LANG['encoding'] = 'Codificação desconhecida: '; $PHPMAILER_LANG['execute'] = 'Não foi possível executar: '; +$PHPMAILER_LANG['extension_missing'] = 'Extensão não existe: '; $PHPMAILER_LANG['file_access'] = 'Não foi possível acessar o arquivo: '; $PHPMAILER_LANG['file_open'] = 'Erro de Arquivo: Não foi possível abrir o arquivo: '; $PHPMAILER_LANG['from_failed'] = 'Os seguintes remetentes falharam: '; $PHPMAILER_LANG['instantiate'] = 'Não foi possível instanciar a função mail.'; $PHPMAILER_LANG['invalid_address'] = 'Endereço de e-mail inválido: '; +$PHPMAILER_LANG['invalid_header'] = 'Nome ou valor de cabeçalho inválido'; +$PHPMAILER_LANG['invalid_hostentry'] = 'hostentry inválido: '; +$PHPMAILER_LANG['invalid_host'] = 'host inválido: '; $PHPMAILER_LANG['mailer_not_supported'] = ' mailer não é suportado.'; $PHPMAILER_LANG['provide_address'] = 'Você deve informar pelo menos um destinatário.'; $PHPMAILER_LANG['recipients_failed'] = 'Erro de SMTP: Os seguintes destinatários falharam: '; $PHPMAILER_LANG['signing'] = 'Erro de Assinatura: '; $PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Connect() falhou.'; +$PHPMAILER_LANG['smtp_code'] = 'Código do servidor SMTP: '; $PHPMAILER_LANG['smtp_error'] = 'Erro de servidor SMTP: '; +$PHPMAILER_LANG['smtp_code_ex'] = 'Informações adicionais do servidor SMTP: '; +$PHPMAILER_LANG['smtp_detail'] = 'Detalhes do servidor SMTP: '; $PHPMAILER_LANG['variable_set'] = 'Não foi possível definir ou redefinir a variável: '; -$PHPMAILER_LANG['extension_missing'] = 'Extensão não existe: '; diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ro.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ro.php index 292ec1e4..45bef915 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ro.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-ro.php @@ -3,25 +3,31 @@ /** * Romanian PHPMailer language file: refer to English translation for definitive list * @package PHPMailer - * @author Alex Florea */ $PHPMAILER_LANG['authenticate'] = 'Eroare SMTP: Autentificarea a eșuat.'; +$PHPMAILER_LANG['buggy_php'] = 'Versiunea instalată de PHP este afectată de o problemă care poate duce la coruperea mesajelor Pentru a preveni această problemă, folosiți SMTP, dezactivați opțiunea mail.add_x_header din php.ini, folosiți MacOS/Linux sau actualizați versiunea de PHP la 7.0.17+ sau 7.1.3+.'; $PHPMAILER_LANG['connect_host'] = 'Eroare SMTP: Conectarea la serverul SMTP a eșuat.'; $PHPMAILER_LANG['data_not_accepted'] = 'Eroare SMTP: Datele nu au fost acceptate.'; $PHPMAILER_LANG['empty_message'] = 'Mesajul este gol.'; $PHPMAILER_LANG['encoding'] = 'Encodare necunoscută: '; $PHPMAILER_LANG['execute'] = 'Nu se poate executa următoarea comandă: '; +$PHPMAILER_LANG['extension_missing'] = 'Lipsește extensia: '; $PHPMAILER_LANG['file_access'] = 'Nu se poate accesa următorul fișier: '; $PHPMAILER_LANG['file_open'] = 'Eroare fișier: Nu se poate deschide următorul fișier: '; $PHPMAILER_LANG['from_failed'] = 'Următoarele adrese From au dat eroare: '; $PHPMAILER_LANG['instantiate'] = 'Funcția mail nu a putut fi inițializată.'; $PHPMAILER_LANG['invalid_address'] = 'Adresa de email nu este validă: '; +$PHPMAILER_LANG['invalid_header'] = 'Numele sau valoarea header-ului nu este validă: '; +$PHPMAILER_LANG['invalid_hostentry'] = 'Hostentry invalid: '; +$PHPMAILER_LANG['invalid_host'] = 'Host invalid: '; $PHPMAILER_LANG['mailer_not_supported'] = ' mailer nu este suportat.'; $PHPMAILER_LANG['provide_address'] = 'Trebuie să adăugați cel puțin o adresă de email.'; $PHPMAILER_LANG['recipients_failed'] = 'Eroare SMTP: Următoarele adrese de email au eșuat: '; $PHPMAILER_LANG['signing'] = 'A aparut o problemă la semnarea emailului. '; +$PHPMAILER_LANG['smtp_code'] = 'Cod SMTP: '; +$PHPMAILER_LANG['smtp_code_ex'] = 'Informații SMTP adiționale: '; $PHPMAILER_LANG['smtp_connect_failed'] = 'Conectarea la serverul SMTP a eșuat.'; +$PHPMAILER_LANG['smtp_detail'] = 'Detalii SMTP: '; $PHPMAILER_LANG['smtp_error'] = 'Eroare server SMTP: '; $PHPMAILER_LANG['variable_set'] = 'Nu se poate seta/reseta variabila. '; -$PHPMAILER_LANG['extension_missing'] = 'Lipsește extensia: '; diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-sl.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-sl.php index c437a886..3e00c259 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-sl.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/language/phpmailer.lang-sl.php @@ -9,23 +9,28 @@ */ $PHPMAILER_LANG['authenticate'] = 'SMTP napaka: Avtentikacija ni uspela.'; +$PHPMAILER_LANG['buggy_php'] = 'Na vašo PHP različico vpliva napaka, ki lahko povzroči poškodovana sporočila. Če želite težavo odpraviti, preklopite na pošiljanje prek SMTP, onemogočite možnost mail.add_x_header v vaši php.ini datoteki, preklopite na MacOS ali Linux, ali nadgradite vašo PHP zaličico na 7.0.17+ ali 7.1.3+.'; $PHPMAILER_LANG['connect_host'] = 'SMTP napaka: Vzpostavljanje povezave s SMTP gostiteljem ni uspelo.'; $PHPMAILER_LANG['data_not_accepted'] = 'SMTP napaka: Strežnik zavrača podatke.'; $PHPMAILER_LANG['empty_message'] = 'E-poštno sporočilo nima vsebine.'; $PHPMAILER_LANG['encoding'] = 'Nepoznan tip kodiranja: '; $PHPMAILER_LANG['execute'] = 'Operacija ni uspela: '; +$PHPMAILER_LANG['extension_missing'] = 'Manjkajoča razširitev: '; $PHPMAILER_LANG['file_access'] = 'Nimam dostopa do datoteke: '; $PHPMAILER_LANG['file_open'] = 'Ne morem odpreti datoteke: '; $PHPMAILER_LANG['from_failed'] = 'Neveljaven e-naslov pošiljatelja: '; $PHPMAILER_LANG['instantiate'] = 'Ne morem inicializirati mail funkcije.'; $PHPMAILER_LANG['invalid_address'] = 'E-poštno sporočilo ni bilo poslano. E-naslov je neveljaven: '; +$PHPMAILER_LANG['invalid_header'] = 'Neveljavno ime ali vrednost glave'; $PHPMAILER_LANG['invalid_hostentry'] = 'Neveljaven vnos gostitelja: '; $PHPMAILER_LANG['invalid_host'] = 'Neveljaven gostitelj: '; $PHPMAILER_LANG['mailer_not_supported'] = ' mailer ni podprt.'; $PHPMAILER_LANG['provide_address'] = 'Prosimo, vnesite vsaj enega naslovnika.'; $PHPMAILER_LANG['recipients_failed'] = 'SMTP napaka: Sledeči naslovniki so neveljavni: '; $PHPMAILER_LANG['signing'] = 'Napaka pri podpisovanju: '; +$PHPMAILER_LANG['smtp_code'] = 'SMTP koda: '; +$PHPMAILER_LANG['smtp_code_ex'] = 'Dodatne informacije o SMTP: '; $PHPMAILER_LANG['smtp_connect_failed'] = 'Ne morem vzpostaviti povezave s SMTP strežnikom.'; +$PHPMAILER_LANG['smtp_detail'] = 'Podrobnosti: '; $PHPMAILER_LANG['smtp_error'] = 'Napaka SMTP strežnika: '; $PHPMAILER_LANG['variable_set'] = 'Ne morem nastaviti oz. ponastaviti spremenljivke: '; -$PHPMAILER_LANG['extension_missing'] = 'Manjkajoča razširitev: '; diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/phpunit.xml.dist b/data/web/inc/lib/vendor/phpmailer/phpmailer/phpunit.xml.dist deleted file mode 100644 index c68df965..00000000 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/phpunit.xml.dist +++ /dev/null @@ -1,35 +0,0 @@ - - - - - ./test/ - - - - - - - - languages - pop3 - - - - - ./src - - - - - - - - diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/Exception.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/Exception.php index a50a8991..52eaf951 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/Exception.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/Exception.php @@ -35,6 +35,6 @@ class Exception extends \Exception */ public function errorMessage() { - return '' . htmlspecialchars($this->getMessage()) . "
\n"; + return '' . htmlspecialchars($this->getMessage(), ENT_COMPAT | ENT_HTML401) . "
\n"; } } diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuth.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuth.php index c93d0be1..c1d5b776 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuth.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuth.php @@ -33,7 +33,7 @@ use League\OAuth2\Client\Token\AccessToken; * * @author Marcus Bointon (Synchro/coolbru) */ -class OAuth +class OAuth implements OAuthTokenProvider { /** * An instance of the League OAuth Client Provider. diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuthTokenProvider.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuthTokenProvider.php new file mode 100644 index 00000000..11555074 --- /dev/null +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/OAuthTokenProvider.php @@ -0,0 +1,44 @@ + + * @author Jim Jagielski (jimjag) + * @author Andy Prevost (codeworxtech) + * @author Brent R. Matzelle (original founder) + * @copyright 2012 - 2020 Marcus Bointon + * @copyright 2010 - 2012 Jim Jagielski + * @copyright 2004 - 2009 Andy Prevost + * @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License + * @note This program is distributed in the hope that it will be useful - WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. + */ + +namespace PHPMailer\PHPMailer; + +/** + * OAuthTokenProvider - OAuth2 token provider interface. + * Provides base64 encoded OAuth2 auth strings for SMTP authentication. + * + * @see OAuth + * @see SMTP::authenticate() + * + * @author Peter Scopes (pdscopes) + * @author Marcus Bointon (Synchro/coolbru) + */ +interface OAuthTokenProvider +{ + /** + * Generate a base64-encoded OAuth token ensuring that the access token has not expired. + * The string to be base 64 encoded should be in the form: + * "user=\001auth=Bearer \001\001" + * + * @return string + */ + public function getOauth64(); +} diff --git a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/PHPMailer.php b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/PHPMailer.php index eb4b742b..718216b5 100644 --- a/data/web/inc/lib/vendor/phpmailer/phpmailer/src/PHPMailer.php +++ b/data/web/inc/lib/vendor/phpmailer/phpmailer/src/PHPMailer.php @@ -103,14 +103,14 @@ class PHPMailer * * @var string */ - public $From = 'root@localhost'; + public $From = ''; /** * The From name of the message. * * @var string */ - public $FromName = 'Root User'; + public $FromName = ''; /** * The envelope sender of the message. @@ -358,9 +358,9 @@ class PHPMailer public $AuthType = ''; /** - * An instance of the PHPMailer OAuth class. + * An implementation of the PHPMailer OAuthTokenProvider interface. * - * @var OAuth + * @var OAuthTokenProvider */ protected $oauth; @@ -689,7 +689,7 @@ class PHPMailer protected $boundary = []; /** - * The array of available languages. + * The array of available text strings for the current language. * * @var array */ @@ -750,7 +750,7 @@ class PHPMailer * * @var string */ - const VERSION = '6.5.0'; + const VERSION = '6.6.0'; /** * Error severity: message only, continue processing. @@ -1185,28 +1185,37 @@ class PHPMailer * * @param string $addrstr The address list string * @param bool $useimap Whether to use the IMAP extension to parse the list + * @param string $charset The charset to use when decoding the address list string. * * @return array */ - public static function parseAddresses($addrstr, $useimap = true) + public static function parseAddresses($addrstr, $useimap = true, $charset = self::CHARSET_ISO88591) { $addresses = []; if ($useimap && function_exists('imap_rfc822_parse_adrlist')) { //Use this built-in parser if it's available $list = imap_rfc822_parse_adrlist($addrstr, ''); + // Clear any potential IMAP errors to get rid of notices being thrown at end of script. + imap_errors(); foreach ($list as $address) { if ( - ('.SYNTAX-ERROR.' !== $address->host) && static::validateAddress( - $address->mailbox . '@' . $address->host - ) + '.SYNTAX-ERROR.' !== $address->host && + static::validateAddress($address->mailbox . '@' . $address->host) ) { //Decode the name part if it's present and encoded if ( property_exists($address, 'personal') && - extension_loaded('mbstring') && - preg_match('/^=\?.*\?=$/', $address->personal) + //Check for a Mbstring constant rather than using extension_loaded, which is sometimes disabled + defined('MB_CASE_UPPER') && + preg_match('/^=\?.*\?=$/s', $address->personal) ) { + $origCharset = mb_internal_encoding(); + mb_internal_encoding($charset); + //Undo any RFC2047-encoded spaces-as-underscores + $address->personal = str_replace('_', '=20', $address->personal); + //Decode the name $address->personal = mb_decode_mimeheader($address->personal); + mb_internal_encoding($origCharset); } $addresses[] = [ @@ -1234,9 +1243,16 @@ class PHPMailer $email = trim(str_replace('>', '', $email)); $name = trim($name); if (static::validateAddress($email)) { + //Check for a Mbstring constant rather than using extension_loaded, which is sometimes disabled //If this name is encoded, decode it - if (preg_match('/^=\?.*\?=$/', $name)) { + if (defined('MB_CASE_UPPER') && preg_match('/^=\?.*\?=$/s', $name)) { + $origCharset = mb_internal_encoding(); + mb_internal_encoding($charset); + //Undo any RFC2047-encoded spaces-as-underscores + $name = str_replace('_', '=20', $name); + //Decode the name $name = mb_decode_mimeheader($name); + mb_internal_encoding($origCharset); } $addresses[] = [ //Remove any surrounding quotes and spaces from the name @@ -1436,7 +1452,12 @@ class PHPMailer $errorcode = 0; if (defined('INTL_IDNA_VARIANT_UTS46')) { //Use the current punycode standard (appeared in PHP 7.2) - $punycode = idn_to_ascii($domain, $errorcode, \INTL_IDNA_VARIANT_UTS46); + $punycode = idn_to_ascii( + $domain, + \IDNA_DEFAULT | \IDNA_USE_STD3_RULES | \IDNA_CHECK_BIDI | + \IDNA_CHECK_CONTEXTJ | \IDNA_NONTRANSITIONAL_TO_ASCII, + \INTL_IDNA_VARIANT_UTS46 + ); } elseif (defined('INTL_IDNA_VARIANT_2003')) { //Fall back to this old, deprecated/removed encoding $punycode = idn_to_ascii($domain, $errorcode, \INTL_IDNA_VARIANT_2003); @@ -1508,12 +1529,7 @@ class PHPMailer && ini_get('mail.add_x_header') === '1' && stripos(PHP_OS, 'WIN') === 0 ) { - trigger_error( - 'Your version of PHP is affected by a bug that may result in corrupted messages.' . - ' To fix it, switch to sending using SMTP, disable the mail.add_x_header option in' . - ' your php.ini, switch to MacOS or Linux, or upgrade your PHP to version 7.0.17+ or 7.1.3+.', - E_USER_WARNING - ); + trigger_error($this->lang('buggy_php'), E_USER_WARNING); } try { @@ -1687,7 +1703,10 @@ class PHPMailer //Sendmail docs: http://www.sendmail.org/~ca/email/man/sendmail.html //Qmail docs: http://www.qmail.org/man/man8/qmail-inject.html //Example problem: https://www.drupal.org/node/1057954 - if (empty($this->Sender) && !empty(ini_get('sendmail_from'))) { + + //PHP 5.6 workaround + $sendmail_from_value = ini_get('sendmail_from'); + if (empty($this->Sender) && !empty($sendmail_from_value)) { //PHP config has a sender address we can use $this->Sender = ini_get('sendmail_from'); } @@ -1724,7 +1743,7 @@ class PHPMailer fwrite($mail, $header); fwrite($mail, $body); $result = pclose($mail); - $addrinfo = static::parseAddresses($toAddr); + $addrinfo = static::parseAddresses($toAddr, true, $this->CharSet); $this->doCallback( ($result === 0), [[$addrinfo['address'], $addrinfo['name']]], @@ -1779,7 +1798,13 @@ class PHPMailer */ protected static function isShellSafe($string) { - //Future-proof + //It's not possible to use shell commands safely (which includes the mail() function) without escapeshellarg, + //but some hosting providers disable it, creating a security problem that we don't want to have to deal with, + //so we don't. + if (!function_exists('escapeshellarg') || !function_exists('escapeshellcmd')) { + return false; + } + if ( escapeshellcmd($string) !== $string || !in_array(escapeshellarg($string), ["'$string'", "\"$string\""]) @@ -1869,7 +1894,10 @@ class PHPMailer //Qmail docs: http://www.qmail.org/man/man8/qmail-inject.html //Example problem: https://www.drupal.org/node/1057954 //CVE-2016-10033, CVE-2016-10045: Don't pass -f if characters will be escaped. - if (empty($this->Sender) && !empty(ini_get('sendmail_from'))) { + + //PHP 5.6 workaround + $sendmail_from_value = ini_get('sendmail_from'); + if (empty($this->Sender) && !empty($sendmail_from_value)) { //PHP config has a sender address we can use $this->Sender = ini_get('sendmail_from'); } @@ -1884,7 +1912,7 @@ class PHPMailer if ($this->SingleTo && count($toArr) > 1) { foreach ($toArr as $toAddr) { $result = $this->mailPassthru($toAddr, $this->Subject, $body, $header, $params); - $addrinfo = static::parseAddresses($toAddr); + $addrinfo = static::parseAddresses($toAddr, true, $this->CharSet); $this->doCallback( $result, [[$addrinfo['address'], $addrinfo['name']]], @@ -2133,7 +2161,8 @@ class PHPMailer } if ($tls) { if (!$this->smtp->startTLS()) { - throw new Exception($this->lang('connect_host')); + $message = $this->getSmtpErrorMessage('connect_host'); + throw new Exception($message); } //We must resend EHLO after TLS negotiation $this->smtp->hello($hello); @@ -2163,6 +2192,10 @@ class PHPMailer //As we've caught all exceptions, just report whatever the last one was if ($this->exceptions && null !== $lastexception) { throw $lastexception; + } elseif ($this->exceptions) { + // no exception was thrown, likely $this->smtp->connect() failed + $message = $this->getSmtpErrorMessage('connect_host'); + throw new Exception($message); } return false; @@ -2181,14 +2214,15 @@ class PHPMailer /** * Set the language for error messages. - * Returns false if it cannot load the language file. * The default language is English. * * @param string $langcode ISO 639-1 2-character language code (e.g. French is "fr") - * @param string $lang_path Path to the language file directory, with trailing separator (slash).D + * Optionally, the language code can be enhanced with a 4-character + * script annotation and/or a 2-character country annotation. + * @param string $lang_path Path to the language file directory, with trailing separator (slash) * Do not set this from user input! * - * @return bool + * @return bool Returns true if the requested language was loaded, false otherwise. */ public function setLanguage($langcode = 'en', $lang_path = '') { @@ -2211,44 +2245,77 @@ class PHPMailer //Define full set of translatable strings in English $PHPMAILER_LANG = [ 'authenticate' => 'SMTP Error: Could not authenticate.', + 'buggy_php' => 'Your version of PHP is affected by a bug that may result in corrupted messages.' . + ' To fix it, switch to sending using SMTP, disable the mail.add_x_header option in' . + ' your php.ini, switch to MacOS or Linux, or upgrade your PHP to version 7.0.17+ or 7.1.3+.', 'connect_host' => 'SMTP Error: Could not connect to SMTP host.', 'data_not_accepted' => 'SMTP Error: data not accepted.', 'empty_message' => 'Message body empty', 'encoding' => 'Unknown encoding: ', 'execute' => 'Could not execute: ', + 'extension_missing' => 'Extension missing: ', 'file_access' => 'Could not access file: ', 'file_open' => 'File Error: Could not open file: ', 'from_failed' => 'The following From address failed: ', 'instantiate' => 'Could not instantiate mail function.', 'invalid_address' => 'Invalid address: ', + 'invalid_header' => 'Invalid header name or value', 'invalid_hostentry' => 'Invalid hostentry: ', 'invalid_host' => 'Invalid host: ', 'mailer_not_supported' => ' mailer is not supported.', 'provide_address' => 'You must provide at least one recipient email address.', 'recipients_failed' => 'SMTP Error: The following recipients failed: ', 'signing' => 'Signing Error: ', + 'smtp_code' => 'SMTP code: ', + 'smtp_code_ex' => 'Additional SMTP info: ', 'smtp_connect_failed' => 'SMTP connect() failed.', + 'smtp_detail' => 'Detail: ', 'smtp_error' => 'SMTP server error: ', 'variable_set' => 'Cannot set or reset variable: ', - 'extension_missing' => 'Extension missing: ', ]; if (empty($lang_path)) { //Calculate an absolute path so it can work if CWD is not here $lang_path = dirname(__DIR__) . DIRECTORY_SEPARATOR . 'language' . DIRECTORY_SEPARATOR; } + //Validate $langcode - if (!preg_match('/^[a-z]{2}(?:_[a-zA-Z]{2})?$/', $langcode)) { + $foundlang = true; + $langcode = strtolower($langcode); + if ( + !preg_match('/^(?P[a-z]{2})(?P