Skip to content

Commit

Permalink
Merge pull request #536 from franmomu/fix_strict_types
Browse files Browse the repository at this point in the history
Fix casting int to string
  • Loading branch information
goetas authored Mar 19, 2020
2 parents 4cf57e8 + 442ac7c commit 162c4ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Translation/Dumper/XliffDumper.php
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ public function dump(MessageCatalogue $catalogue, $domain = 'messages')

foreach ($catalogue->getDomain($domain)->all() as $id => $message) {
$body->appendChild($unit = $doc->createElement('trans-unit'));
$unit->setAttribute('id', hash('sha1', $id));
$unit->setAttribute('id', hash('sha1', (string) $id));
$unit->setAttribute('resname', (string) $id);
if ($message instanceof XliffMessage && $message->isApproved()) {
$unit->setAttribute('approved', 'yes');
Expand Down Expand Up @@ -203,7 +203,7 @@ public function dump(MessageCatalogue $catalogue, $domain = 'messages')
*
* @param array $sources
*
* @return FileSource
* @return array
*/
protected function getSortedSources(array $sources)
{
Expand Down

0 comments on commit 162c4ae

Please sign in to comment.