Permalink
Browse files

No need to unwrap to an array

Since OpenPGP_Message implements the array interface
  • Loading branch information...
1 parent 975fc2f commit 1a1b8980e6c6a985415f1fd85ad16e8400caa2b1 @singpolyma singpolyma committed Mar 31, 2010
Showing with 1 addition and 4 deletions.
  1. +1 −4 lib/openpgp.php
View
@@ -790,15 +790,12 @@ function read() {
default:
/* TODO error? */
}
- if($this->data) {
- $this->data = $this->data->packets;
- }
}
// IteratorAggregate interface
function getIterator() {
- return new ArrayIterator($this->data);
+ return new ArrayIterator($this->data->packets);
}
// ArrayAccess interface

0 comments on commit 1a1b898

Please sign in to comment.