Uploaded image for project: 'Blesta Core'
  1. Blesta Core
  2. CORE-5071

Internet.bs: Error when managing domains

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.9.3
    • Component/s: None
    • Labels:
      None

      Description

      To reproduce:
      1. Create a internet bs domain on a tld with no special fields
      2. Try to manage the domain

      To resolve:
      In components\modules\internetbs\internetbs.php around line 1964 (AND IN ALL OTHER LOCATIONS) change:

                  $fields = array_merge(
                      Configure::get('Internetbs.nameserver_fields'),
                      Configure::get('Internetbs.domain_fields'),
                      Configure::get('Internetbs.domain_fields' . $tld)
                  );
      

      to

      
                  $fields = array_merge(
                      Configure::get('Internetbs.nameserver_fields'),
                      Configure::get('Internetbs.domain_fields'),
                      (array) Configure::get('Internetbs.domain_fields' . $tld)
                  );
      

      Original error:

      [2024-02-02T17:16:58.800305+00:00] general.ERROR: Uncaught Exception TypeError: "array_merge(): Argument #3 must be of type array, null given" at /home/hostinpk/clients/components/modules/internetbs/internetbs.php line 1967 {"exception":"[object] (TypeError(code: 0): array_merge(): Argument #3 must be of type array, null given at /home/hostinpk/clients/components/modules/internetbs/internetbs.php:1967)"}
      [2024-02-02T17:17:01.819476+00:00] general.ERROR: Uncaught Exception TypeError: "array_merge(): Argument #3 must be of type array, null given" at /home/hostinpk/clients/components/modules/internetbs/internetbs.php line 1967 {"exception":"[object] (TypeError(code: 0): array_merge(): Argument #3 must be of type array, null given at /home/hostinpk/clients/components/modules/internetbs/internetbs.php:1967)"}
      

        Activity

        jonathan Jonathan Reissmueller created issue -
        jonathan Jonathan Reissmueller made changes -
        Field Original Value New Value
        Sprint 5.10.0 Sprint 5 [ 192 ]
        jonathan Jonathan Reissmueller made changes -
        Rank Ranked higher
        jonathan Jonathan Reissmueller made changes -
        Description To reproduce:
        1. Create a internet bs domain on a tld with no special fields
        2. Try to manage the domain

        To resolve:
        In components\modules\internetbs\internetbs.php around line 1964 change:
        ```
                    $fields = array_merge(
                        Configure::get('Internetbs.nameserver_fields'),
                        Configure::get('Internetbs.domain_fields'),
                        Configure::get('Internetbs.domain_fields' . $tld)
                    );
        ```
        to
        ```

                    $fields = array_merge(
                        Configure::get('Internetbs.nameserver_fields'),
                        Configure::get('Internetbs.domain_fields'),
                        Configure::get('Internetbs.domain_fields' . $tld) ?? []
                    );
        ```
        Original error:
        {code:java}
        [2024-02-02T17:16:58.800305+00:00] general.ERROR: Uncaught Exception TypeError: "array_merge(): Argument #3 must be of type array, null given" at /home/hostinpk/clients/components/modules/internetbs/internetbs.php line 1967 {"exception":"[object] (TypeError(code: 0): array_merge(): Argument #3 must be of type array, null given at /home/hostinpk/clients/components/modules/internetbs/internetbs.php:1967)"}
        [2024-02-02T17:17:01.819476+00:00] general.ERROR: Uncaught Exception TypeError: "array_merge(): Argument #3 must be of type array, null given" at /home/hostinpk/clients/components/modules/internetbs/internetbs.php line 1967 {"exception":"[object] (TypeError(code: 0): array_merge(): Argument #3 must be of type array, null given at /home/hostinpk/clients/components/modules/internetbs/internetbs.php:1967)"}
        {code}
        To reproduce:
        1. Create a internet bs domain on a tld with no special fields
        2. Try to manage the domain

        To resolve:
        In components\modules\internetbs\internetbs.php around line 1964 (AND IN ALL OTHER LOCATIONS) change:

        {code:java}
                    $fields = array_merge(
                        Configure::get('Internetbs.nameserver_fields'),
                        Configure::get('Internetbs.domain_fields'),
                        Configure::get('Internetbs.domain_fields' . $tld)
                    );
        {code}


        to


        {code:java}

                    $fields = array_merge(
                        Configure::get('Internetbs.nameserver_fields'),
                        Configure::get('Internetbs.domain_fields'),
                        (array) Configure::get('Internetbs.domain_fields' . $tld)
                    );
        {code}


        Original error:
        {code:java}
        [2024-02-02T17:16:58.800305+00:00] general.ERROR: Uncaught Exception TypeError: "array_merge(): Argument #3 must be of type array, null given" at /home/hostinpk/clients/components/modules/internetbs/internetbs.php line 1967 {"exception":"[object] (TypeError(code: 0): array_merge(): Argument #3 must be of type array, null given at /home/hostinpk/clients/components/modules/internetbs/internetbs.php:1967)"}
        [2024-02-02T17:17:01.819476+00:00] general.ERROR: Uncaught Exception TypeError: "array_merge(): Argument #3 must be of type array, null given" at /home/hostinpk/clients/components/modules/internetbs/internetbs.php line 1967 {"exception":"[object] (TypeError(code: 0): array_merge(): Argument #3 must be of type array, null given at /home/hostinpk/clients/components/modules/internetbs/internetbs.php:1967)"}
        {code}
        jonathan Jonathan Reissmueller made changes -
        Fix Version/s 5.9.2 [ 11910 ]
        Fix Version/s 5.10.0-b1 [ 11905 ]
        abdy Abdy Franco made changes -
        Assignee Abdy Franco [ abdy ]
        abdy Abdy Franco made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        abdy Abdy Franco made changes -
        Remaining Estimate 0 minutes [ 0 ]
        Time Spent 31 minutes [ 1860 ]
        Worklog Id 16843 [ 16843 ]
        abdy Abdy Franco made changes -
        Status In Progress [ 3 ] In Review [ 5 ]
        Resolution Fixed [ 1 ]
        jonathan Jonathan Reissmueller made changes -
        Sprint 5.10.0 Sprint 5 [ 192 ] 5.10.0 Sprint 5, 5.10.0 Sprint 6 [ 192, 193 ]
        jonathan Jonathan Reissmueller made changes -
        Rank Ranked higher
        jonathan Jonathan Reissmueller made changes -
        Fix Version/s 5.9.3 [ 11913 ]
        Fix Version/s 5.9.2 [ 11910 ]
        Original Estimate 0 minutes [ 0 ]
        jonathan Jonathan Reissmueller made changes -
        Rank Ranked lower
        jonathan Jonathan Reissmueller made changes -
        Status In Review [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            abdy Abdy Franco
            Reporter:
            jonathan Jonathan Reissmueller
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:
              Fix Release Date:
              21/Feb/24

              Time Tracking

              Estimated:
              Original Estimate - 0 minutes
              0m
              Remaining:
              Remaining Estimate - 0 minutes
              0m
              Logged:
              Time Spent - 31 minutes
              31m

                Agile