Code Duplication    Length = 16-16 lines in 3 locations

packages/core/src/Models/Task/Base/Task.php 1 location

@@ 193-208 (lines=16) @@
190
     * @param  mixed   $obj The object to compare to.
191
     * @return boolean Whether equal to the object specified.
192
     */
193
    public function equals($obj)
194
    {
195
        if (!$obj instanceof static) {
196
            return false;
197
        }
198
199
        if ($this === $obj) {
200
            return true;
201
        }
202
203
        if (null === $this->getPrimaryKey() || null === $obj->getPrimaryKey()) {
204
            return false;
205
        }
206
207
        return $this->getPrimaryKey() === $obj->getPrimaryKey();
208
    }
209
210
    /**
211
     * Get the associative array of the virtual columns in this object

packages/core/src/Models/User/Base/User.php 1 location

@@ 244-259 (lines=16) @@
241
     * @param  mixed   $obj The object to compare to.
242
     * @return boolean Whether equal to the object specified.
243
     */
244
    public function equals($obj)
245
    {
246
        if (!$obj instanceof static) {
247
            return false;
248
        }
249
250
        if ($this === $obj) {
251
            return true;
252
        }
253
254
        if (null === $this->getPrimaryKey() || null === $obj->getPrimaryKey()) {
255
            return false;
256
        }
257
258
        return $this->getPrimaryKey() === $obj->getPrimaryKey();
259
    }
260
261
    /**
262
     * Get the associative array of the virtual columns in this object

packages/selfprice/src/Models/Selfprice/Base/Selfprice.php 1 location

@@ 199-214 (lines=16) @@
196
     * @param  mixed   $obj The object to compare to.
197
     * @return boolean Whether equal to the object specified.
198
     */
199
    public function equals($obj)
200
    {
201
        if (!$obj instanceof static) {
202
            return false;
203
        }
204
205
        if ($this === $obj) {
206
            return true;
207
        }
208
209
        if (null === $this->getPrimaryKey() || null === $obj->getPrimaryKey()) {
210
            return false;
211
        }
212
213
        return $this->getPrimaryKey() === $obj->getPrimaryKey();
214
    }
215
216
    /**
217
     * Get the associative array of the virtual columns in this object