summaryrefslogtreecommitdiff
blob: 3527814485abfc75950c431b6220556a0b918445 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
diff -aurN a/File/Gettext/MO.php b/File/Gettext/MO.php
--- a/File/Gettext/MO.php	2012-03-03 22:00:49.000000000 -0500
+++ b/File/Gettext/MO.php	2018-02-16 15:15:17.725027132 -0500
@@ -60,6 +60,10 @@
      * @access  public
      * @return  object      File_Gettext_MO
      */
+    function __construct($file = '')
+    {
+        $this->file = $file;
+    }
     function File_Gettext_MO($file = '')
     {
         $this->file = $file;
diff -aurN a/File/Gettext/PO.php b/File/Gettext/PO.php
--- a/File/Gettext/PO.php	2012-03-03 22:00:49.000000000 -0500
+++ b/File/Gettext/PO.php	2018-02-16 15:14:57.997419162 -0500
@@ -42,6 +42,10 @@
      * @access  public
      * @return  object      File_Gettext_PO
      */
+    function __construct($file = '')
+    {
+        $this->file = $file;
+    }
     function File_Gettext_PO($file = '')
     {
         $this->file = $file;
diff -aurN a/File/Gettext.php b/File/Gettext.php
--- a/File/Gettext.php	2012-03-03 22:00:49.000000000 -0500
+++ b/File/Gettext.php	2018-02-16 15:14:27.629022634 -0500
@@ -85,7 +85,7 @@
             return File_Gettext::raiseError($php_errormsg);
         }
         $class = 'File_Gettext_' . $format;
-        $obref = &new $class($file);
+        $obref = new $class($file);
         return $obref;
     }
 
@@ -110,7 +110,7 @@
 
         include_once 'File/Gettext/PO.php';
 
-        $PO = &new File_Gettext_PO($pofile);
+        $PO = new File_Gettext_PO($pofile);
         if (true !== ($e = $PO->load())) {
             return $e;
         }
@@ -247,7 +247,7 @@
     function &toMO()
     {
         include_once 'File/Gettext/MO.php';
-        $MO = &new File_Gettext_MO;
+        $MO = new File_Gettext_MO;
         $MO->fromArray($this->toArray());
         return $MO;
     }
@@ -261,7 +261,7 @@
     function &toPO()
     {
         include_once 'File/Gettext/PO.php';
-        $PO = &new File_Gettext_PO;
+        $PO = new File_Gettext_PO;
         $PO->fromArray($this->toArray());
         return $PO;
     }