I'm trying to use the centerOnLayer() call, but it fails with an exception: No structure encoding found for CGRect. Any ideas what I'm doing wrong?
var Document = require('sketch/dom').Document
var document = Document.getSelectedDocument()
var layer = document.getLayerWithID("0B6AEB39-63B9-4DD1-B179-BBBCAE50B170");
if (layer) {
document.centerOnLayer(layer);
}