You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For example, Piwik::Referers.getKeywords will normally return an array of hashes if the site has multiple keywords.
However, if the site is new and has a single keyword, won't return a hash but instead a single hash. Instead, that same hash should be returned inside an array to reduce the extra code necessary.
If a site has no keywords, the response is a single hash: {"nb_visits" => 0}
This is not only unnecessary, but it is yet again another case that require extra code to be written.
Instead, an empty array should be the result.
The text was updated successfully, but these errors were encountered:
For example, Piwik::Referers.getKeywords will normally return an array of hashes if the site has multiple keywords.
However, if the site is new and has a single keyword, won't return a hash but instead a single hash. Instead, that same hash should be returned inside an array to reduce the extra code necessary.
If a site has no keywords, the response is a single hash:
{"nb_visits" => 0}
This is not only unnecessary, but it is yet again another case that require extra code to be written.
Instead, an empty array should be the result.
The text was updated successfully, but these errors were encountered: