[Pkg-owncloud-commits] [owncloud] 165/215: implement json serialize for l10n string

David Prévot taffit at moszumanska.debian.org
Tue May 5 01:01:45 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch stable8
in repository owncloud.

commit 5b857a6eabd6ae4616a4f4757ce426e2ea15d313
Author: Bernhard Posselt <dev at bernhard-posselt.com>
Date:   Wed Apr 29 21:22:42 2015 +0200

    implement json serialize for l10n string
---
 lib/private/l10n/string.php | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/lib/private/l10n/string.php b/lib/private/l10n/string.php
index 6167a67..dd86163 100644
--- a/lib/private/l10n/string.php
+++ b/lib/private/l10n/string.php
@@ -24,7 +24,9 @@
  *
  */
 
-class OC_L10N_String{
+use JsonSerializable;
+
+class OC_L10N_String implements JsonSerializable {
 	/**
 	 * @var OC_L10N
 	 */
@@ -74,4 +76,10 @@ class OC_L10N_String{
 		$text = str_replace('%n', $this->count, $text);
 		return vsprintf($text, $this->parameters);
 	}
+
+
+	public function jsonSerialize() {
+		return $this->__toString();
+	}
+
 }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git



More information about the Pkg-owncloud-commits mailing list