mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-01-25 23:58:39 +00:00
automated phpcs fixes
This commit is contained in:
parent
c2538fed60
commit
f88a530b96
|
|
@ -353,6 +353,18 @@ abstract class DataMapperAbstract
|
|||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Define the joining data
|
||||
*
|
||||
* @param string $member Property name to filter by
|
||||
* @param mixed $value Filter value
|
||||
* @param string $logic Comparison logic (e.g. =, in, ...)
|
||||
* @param string $connector Filter connector (e.g. AND, OR, ...)
|
||||
*
|
||||
* @return self
|
||||
*
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public function on(string $member, mixed $value, string $logic = '=', string $connector = 'AND', string $relation = '') : self
|
||||
{
|
||||
$this->on[$relation][] = [
|
||||
|
|
|
|||
|
|
@ -404,7 +404,7 @@ final class HttpRequest extends RequestAbstract
|
|||
public function getLocale() : string
|
||||
{
|
||||
if (!empty($this->locale)) {
|
||||
return $this->locale = $this->header->l11n->language . '_' . $this->header->l11n->getCountry();
|
||||
return $this->locale = $this->header->l11n->language . '_' . $this->header->l11n->country;
|
||||
}
|
||||
|
||||
if (!isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {
|
||||
|
|
|
|||
|
|
@ -156,6 +156,17 @@ final class EncryptionHelper
|
|||
return $plaintext === false ? '' : $plaintext;
|
||||
}
|
||||
|
||||
/**
|
||||
* Decrypt an encrypted file
|
||||
*
|
||||
* @param string $in Encrypted file
|
||||
* @param string $out Decrypted file
|
||||
* @param string $keyHex Shared key in hex
|
||||
*
|
||||
* @return bool
|
||||
*
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public static function decryptFile(string $in, string $out, string $keyHex) : bool
|
||||
{
|
||||
$fpSource = \fopen($in, 'rb');
|
||||
|
|
|
|||
|
|
@ -2725,14 +2725,15 @@ class QR extends TwoDAbstract
|
|||
$rs['gfpoly'] = $gfpoly;
|
||||
|
||||
// Find prim-th root of 1, used in decoding
|
||||
for ($iprim=1; ($iprim % $prim) !== 0; $iprim += $rs['nn']) {
|
||||
// intentional empty-body loop!
|
||||
$iprim = 1;
|
||||
while ($iprim % $prim !== 0) {
|
||||
$iprim += $rs['nn'];
|
||||
}
|
||||
|
||||
$rs['iprim'] = (int) ($iprim / $prim);
|
||||
$rs['genpoly'][0] = 1;
|
||||
|
||||
for ($i = 0,$root = $fcr * $prim; $i < $nroots; $i++, $root += $prim) {
|
||||
for ($i = 0, $root = $fcr * $prim; $i < $nroots; ++$i, $root += $prim) {
|
||||
$rs['genpoly'][$i + 1] = 1;
|
||||
|
||||
// Multiply rs->genpoly[] by @**(root + x)
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ final class ViewTest extends \PHPUnit\Framework\TestCase
|
|||
*/
|
||||
public function testHasData() : void
|
||||
{
|
||||
$view = new View($this->app->l11nManager);
|
||||
$view = new View($this->app->l11nManager);
|
||||
$view->data['a'] = 1;
|
||||
|
||||
self::assertTrue($view->hasData('a'));
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user