You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ti...@apache.org on 2021/01/22 17:06:43 UTC

[cordova-plugin-screen-orientation] branch master updated: fix: resolveOrientation function not working correctly (#77)

This is an automated email from the ASF dual-hosted git repository.

timbru31 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-plugin-screen-orientation.git


The following commit(s) were added to refs/heads/master by this push:
     new e0a1f39  fix: resolveOrientation function not working correctly (#77)
e0a1f39 is described below

commit e0a1f3948cbc05bd6895e66b46d735ab45bd8b70
Author: iktumi <46...@users.noreply.github.com>
AuthorDate: Fri Jan 22 17:06:37 2021 +0000

    fix: resolveOrientation function not working correctly (#77)
    
    Fixing a problem that was making the screen not to be locked as described on https://www.outsystems.com/forums/discussion/67761/resolveorientation-bug/
---
 www/screenorientation.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/www/screenorientation.js b/www/screenorientation.js
index d8fe529..4e98e9a 100644
--- a/www/screenorientation.js
+++ b/www/screenorientation.js
@@ -84,7 +84,7 @@ function addScreenOrientationApi (screenObject) {
 }
 
 function resolveOrientation (orientation, resolve, reject) {
-    if (!Object.prototype.hasOwnProperty.call(OrientationLockType, 'orientation')) {
+    if (!Object.prototype.hasOwnProperty.call(OrientationLockType, orientation)) {
         var err = new Error();
         err.name = 'NotSupportedError';
         reject(err); // "cannot change orientation");


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org