Compare commits

...

16 commits

Author SHA1 Message Date
aef0637949 update composer 2022-04-04 16:33:18 +02:00
ce00940822 fix notice "Notice: Undefined property: stdClass::$dparameters" 2022-04-04 16:33:11 +02:00
Clivern
135ea0091d bump pkgs 2020-07-15 22:49:43 +02:00
Ahmed
8cc04995f6
Update .travis.yml 2020-02-10 19:52:38 +01:00
renovate[bot]
3614c9a2d2
Update dependency squizlabs/php_codesniffer to v3.5.4 (#23)
Co-authored-by: WhiteSource Renovate <renovatebot@gmail.com>
2020-01-31 15:49:02 +01:00
renovate[bot]
be3a950124 Update dependency squizlabs/php_codesniffer to v3.5.3 (#19)
Co-authored-by: WhiteSource Renovate <renovatebot@gmail.com>
2020-01-28 18:46:46 +01:00
renovate[bot]
a0e85dc592 Pin dependencies (#16) 2019-12-01 21:49:31 +01:00
Ahmed
db54d30366
Merge pull request #15 from Clivern/renovate/configure
Configure Renovate
2019-11-22 09:54:18 +01:00
Renovate Bot
585d549be8
Add renovate.json 2019-11-20 20:35:07 +00:00
Ahmed
0da2fd37d9
Merge pull request #14 from Clivern/bugfix/wrong-class
#13 - Fix Attachment Class Name
2019-11-13 12:25:59 +01:00
Clivern
3a97db9625 Fix the thing 2019-11-13 12:22:12 +01:00
Ahmed
b7120d8e3b
Update .travis.yml 2019-11-07 16:55:43 +01:00
Clivern
9a90fc964b Fix attachment class name 2019-11-07 16:47:51 +01:00
A. F
0f512e9680
Update phpcs.xml 2019-02-25 19:53:10 +01:00
A. F
508fbd936a
Create CONTRIBUTING.md 2019-02-25 19:43:42 +01:00
A. F
0ebf39572e
Create CODE_OF_CONDUCT.md 2019-02-25 19:42:52 +01:00
17 changed files with 1309 additions and 324 deletions

View file

@ -4,6 +4,9 @@ php:
- 5.6
- 7.0
- 7.1
- 7.2
- 7.3
- 7.4
## Cache composer
cache:
@ -15,4 +18,4 @@ before_script:
- travis_retry composer update ${COMPOSER_FLAGS} --no-interaction --prefer-dist
script:
- make ci
- make ci

76
CODE_OF_CONDUCT.md Normal file
View file

@ -0,0 +1,76 @@
# Contributor Covenant Code of Conduct
## Our Pledge
In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, sex characteristics, gender identity and expression,
level of experience, education, socio-economic status, nationality, personal
appearance, race, religion, or sexual identity and orientation.
## Our Standards
Examples of behavior that contributes to creating a positive environment
include:
* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery and unwelcome sexual attention or
advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic
address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting
## Our Responsibilities
Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.
Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.
## Scope
This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
representing a project or community include using an official project e-mail
address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at hello@clivern.com. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.
Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
[homepage]: https://www.contributor-covenant.org
For answers to common questions about this code of conduct, see
https://www.contributor-covenant.org/faq

13
CONTRIBUTING.md Normal file
View file

@ -0,0 +1,13 @@
## Contributing
- With issues:
- Use the search tool before opening a new issue.
- Please provide source code and commit sha if you found a bug.
- Review existing issues and provide feedback or react to them.
- With pull requests:
- Open your pull request against `master`
- Your pull request should have no more than two commits, if not you should squash them.
- It should pass all tests in the available continuous integrations systems such as TravisCI.
- You should add/modify tests to cover your proposed code changes.
- If your pull request contains a new feature, please document it on the README.

View file

@ -1,6 +1,6 @@
MIT License
Copyright (c) 2017 Cliven
Copyright (c) 2019 Cliven
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

View file

@ -2,7 +2,7 @@ Imap
====
:mailbox_with_mail: Access Mailbox Using PHP IMAP.
*Current Version: 1.0.5*
*Current Version: 1.0.6*
[![Build Status](https://travis-ci.org/Clivern/Imap.svg?branch=master)](https://travis-ci.org/Clivern/Imap)
@ -265,6 +265,11 @@ Misc
Changelog
---------
Version 1.0.6:
```
Fix Class Name.
```
Version 1.0.5:
```
Enhance code style.
@ -299,6 +304,6 @@ Initial Release.
Acknowledgements
----------------
© 2017, Clivern. Released under the [MIT License](http://www.opensource.org/licenses/mit-license.php).
© 2019, Clivern. Released under the [MIT License](http://www.opensource.org/licenses/mit-license.php).
**Imap** is authored and maintained by [@clivern](http://github.com/clivern).

View file

@ -1,5 +1,5 @@
{
"name": "clivern/imap",
"name": "deblan/clivern-imap",
"type": "library",
"description": "Access Mailbox Using PHP IMAP",
"keywords": ["clivern", "imap"],
@ -16,9 +16,9 @@
"php": ">=5.6.4"
},
"require-dev": {
"phpunit/phpunit": "~5.7",
"friendsofphp/php-cs-fixer": "^2.14",
"squizlabs/php_codesniffer": "^3.4"
"phpunit/phpunit": "5.7.27",
"friendsofphp/php-cs-fixer": "2.16.1",
"squizlabs/php_codesniffer": "3.5.4"
},
"autoload": {
"psr-4": {

1510
composer.lock generated

File diff suppressed because it is too large Load diff

View file

@ -1,7 +1,7 @@
<?xml version="1.0"?>
<ruleset name="MessageBirdCodingStandard">
<ruleset name="ImapCodingStandard">
<description>Imap coding standard.</description>
<file>src</file>
<file>tests</file>
<rule ref="PSR2" />
</ruleset>
</ruleset>

5
renovate.json Normal file
View file

@ -0,0 +1,5 @@
{
"extends": [
"config:base"
]
}

View file

@ -54,8 +54,6 @@ class Message
/**
* Message Constructor.
*
* @param Connection $connection
*/
public function __construct(Connection $connection, Header $header, Action $action, Body $body)
{

View file

@ -31,8 +31,6 @@ class Action
/**
* Class Constructor.
*
* @param Connection $connection
*/
public function __construct(Connection $connection)
{

View file

@ -41,8 +41,6 @@ class Attachment
/**
* Class Constructor.
*
* @param Connection $connection
*/
public function __construct(Connection $connection)
{
@ -228,7 +226,7 @@ class Attachment
$this->attachment['ifdparameters'] = (isset($this->part->ifdparameters)) ? $this->part->ifdparameters : false;
$this->attachment['ifparameters'] = (isset($this->part->ifparameters)) ? $this->part->ifparameters : false;
if (\is_array($this->part->dparameters)) {
if (isset($this->part->dparameters) && \is_array($this->part->dparameters)) {
foreach ($this->part->dparameters as $obj) {
if (\in_array(mb_strtolower($obj->attribute), ['filename', 'name'], true)) {
$this->attachment[mb_strtolower($obj->attribute)] = pathinfo($obj->value, PATHINFO_FILENAME);
@ -237,7 +235,7 @@ class Attachment
}
}
if (\is_array($this->part->parameters)) {
if (isset($this->part->parameters) && \is_array($this->part->parameters)) {
foreach ($this->part->parameters as $obj) {
if (\in_array(mb_strtolower($obj->attribute), ['filename', 'name'], true)) {
$this->attachment[mb_strtolower($obj->attribute)] = pathinfo($obj->value, PATHINFO_FILENAME);

View file

@ -41,8 +41,6 @@ class Body
/**
* Class Constructor.
*
* @param Connection $connection
*/
public function __construct(Connection $connection)
{

View file

@ -36,8 +36,6 @@ class Header
/**
* Class Constructor.
*
* @param Connection $connection
*/
public function __construct(Connection $connection)
{

View file

@ -23,9 +23,6 @@ class MessageIterator extends \ArrayIterator
/**
* Constructor.
*
* @param Connection $connection
* @param array $message_numbers
*/
public function __construct(Connection $connection, array $message_numbers)
{

View file

@ -32,8 +32,6 @@ class Search
/**
* Add Condition.
*
* @param Condition $condition
*
* @return Search
*/
public function addCondition(Condition $condition)

View file

@ -11,7 +11,7 @@ use Clivern\Imap\Core\Connection;
use Clivern\Imap\Core\Exception\FolderNotExistException;
use Clivern\Imap\Core\Message;
use Clivern\Imap\Core\Message\Action;
use Clivern\Imap\Core\Message\Attachments;
use Clivern\Imap\Core\Message\Attachment;
use Clivern\Imap\Core\Message\Body;
use Clivern\Imap\Core\Message\Header;
use Clivern\Imap\Core\MessageIterator;
@ -124,7 +124,7 @@ class MailBox
$this->connection,
new Header($this->connection),
new Action($this->connection),
new Attachments($this->connection),
new Attachment($this->connection),
new Body($this->connection)
);