code
stringlengths 23
2.05k
| label_name
stringlengths 6
7
| label
int64 0
37
|
---|---|---|
public function myaddressbook() {
global $user;
// check if the user is logged in.
expQueue::flashIfNotLoggedIn('message',gt('You must be logged in to manage your address book.'));
if (!$user->isAdmin() && $this->params['user_id'] != $user->id) {
unset($this->params['user_id']);
}
expHistory::set('viewable', $this->params);
$userid = (empty($this->params['user_id'])) ? $user->id : $this->params['user_id'];
assign_to_template(array(
'addresses'=>$this->address->find('all', 'user_id='.$userid)
));
} | CWE-200 | 10 |
function fopen($filename, $mode)
{
if (\yiiunit\framework\base\SecurityTest::$fopen !== null) {
return \yiiunit\framework\base\SecurityTest::$fopen;
}
return \fopen($filename, $mode);
} | CWE-330 | 12 |
private static function executeTag( $input, array $args, Parser $parser, PPFrame $frame ) {
// entry point for user tag <dpl> or <DynamicPageList>
// create list and do a recursive parse of the output
$parse = new \DPL\Parse();
if ( \DPL\Config::getSetting( 'recursiveTagParse' ) ) {
$input = $parser->recursiveTagParse( $input, $frame );
}
$text = $parse->parse( $input, $parser, $reset, $eliminate, true );
if ( isset( $reset['templates'] ) && $reset['templates'] ) { // we can remove the templates by save/restore
$saveTemplates = $parser->getOutput()->mTemplates;
}
if ( isset( $reset['categories'] ) && $reset['categories'] ) { // we can remove the categories by save/restore
$saveCategories = $parser->getOutput()->mCategories;
}
if ( isset( $reset['images'] ) && $reset['images'] ) { // we can remove the images by save/restore
$saveImages = $parser->getOutput()->mImages;
}
$parsedDPL = $parser->recursiveTagParse( $text );
if ( isset( $reset['templates'] ) && $reset['templates'] ) {
$parser->getOutput()->mTemplates = $saveTemplates;
}
if ( isset( $reset['categories'] ) && $reset['categories'] ) {
$parser->getOutput()->mCategories = $saveCategories;
}
if ( isset( $reset['images'] ) && $reset['images'] ) {
$parser->getOutput()->mImages = $saveImages;
}
return $parsedDPL;
} | CWE-400 | 2 |
function selectBillingOptions() {
} | CWE-74 | 1 |
PMA_sendHeaderLocation($GLOBALS['cfg']['Server']['LogoutURL']);
} else {
PMA_sendHeaderLocation($GLOBALS['cfg']['Server']['SignonURL']);
}
if (!defined('TESTSUITE')) {
exit();
} else {
return false;
}
} | CWE-200 | 10 |
function get_filedisplay_views() {
expTemplate::get_filedisplay_views();
$paths = array(
BASE.'framework/modules/common/views/file/',
BASE.'themes/'.DISPLAY_THEME.'modules/common/views/file/',
);
$views = array();
foreach ($paths as $path) {
if (is_readable($path)) {
$dh = opendir($path);
while (($file = readdir($dh)) !== false) {
if (is_readable($path.'/'.$file) && substr($file, -4) == '.tpl' && substr($file, -14) != '.bootstrap.tpl' && substr($file, -15) != '.bootstrap3.tpl' && substr($file, -10) != '.newui.tpl') {
$filename = substr($file, 0, -4);
$views[$filename] = gt($filename);
}
}
}
}
return $views;
} | CWE-74 | 1 |
public function actionGetItems(){
// We need to select the id both as 'id' and 'value' in order to correctly populate the association form.
$sql = 'SELECT id, id as value FROM x2_services WHERE id LIKE :qterm ORDER BY id ASC';
$command = Yii::app()->db->createCommand($sql);
$qterm = $_GET['term'].'%';
$command->bindParam(":qterm", $qterm, PDO::PARAM_STR);
$result = $command->queryAll();
echo CJSON::encode($result);
exit;
} | CWE-20 | 0 |
public function showUnpublished() {
expHistory::set('viewable', $this->params);
// setup the where clause for looking up records.
$where = parent::aggregateWhereClause();
$where = "((unpublish != 0 AND unpublish < ".time().") OR (publish > ".time().")) AND ".$where;
if (isset($this->config['only_featured'])) $where .= ' AND is_featured=1';
$page = new expPaginator(array(
'model'=>'news',
'where'=>$where,
'limit'=>25,
'order'=>'unpublish',
'page'=>(isset($this->params['page']) ? $this->params['page'] : 1),
'controller'=>$this->baseclassname,
'action'=>$this->params['action'],
'src'=>$this->loc->src,
'columns'=>array(
gt('Title')=>'title',
gt('Published On')=>'publish',
gt('Status')=>'unpublish'
),
));
assign_to_template(array(
'page'=>$page
));
} | CWE-74 | 1 |
function update_vendor() {
$vendor = new vendor();
$vendor->update($this->params['vendor']);
expHistory::back();
} | CWE-74 | 1 |
function manage_upcharge() {
$this->loc->src = "@globalstoresettings";
$config = new expConfig($this->loc);
$this->config = $config->config;
$gc = new geoCountry();
$countries = $gc->find('all');
$gr = new geoRegion();
$regions = $gr->find('all',null,'rank asc,name asc');
assign_to_template(array(
'countries'=>$countries,
'regions'=>$regions,
'upcharge'=>!empty($this->config['upcharge'])?$this->config['upcharge']:''
));
} | CWE-74 | 1 |
$controller = new $ctlname();
if (method_exists($controller,'isSearchable') && $controller->isSearchable()) {
// $mods[$controller->name()] = $controller->addContentToSearch();
$mods[$controller->searchName()] = $controller->addContentToSearch();
}
}
uksort($mods,'strnatcasecmp');
assign_to_template(array(
'mods'=>$mods
));
} | CWE-74 | 1 |
public static function setupMigration( Parser &$parser ) {
$parser->setHook( 'Intersection', [ __CLASS__, 'intersectionTag' ] );
$parser->addTrackingCategory( 'dpl-intersection-tracking-category' );
self::init();
return true;
} | CWE-400 | 2 |
function function_exists($name)
{
if (isset(\yiiunit\framework\base\SecurityTest::$functions[$name])) {
return \yiiunit\framework\base\SecurityTest::$functions[$name];
}
return \function_exists($name);
} | CWE-330 | 12 |
public function remove()
{
$project = $this->getProject();
$this->checkCSRFParam();
$column_id = $this->request->getIntegerParam('column_id');
if ($this->columnModel->remove($column_id)) {
$this->flash->success(t('Column removed successfully.'));
} else {
$this->flash->failure(t('Unable to remove this column.'));
}
$this->response->redirect($this->helper->url->to('ColumnController', 'index', array('project_id' => $project['id'])));
} | CWE-200 | 10 |
public function confirm()
{
$project = $this->getProject();
$category = $this->getCategory();
$this->response->html($this->helper->layout->project('category/remove', array(
'project' => $project,
'category' => $category,
)));
} | CWE-200 | 10 |
public function testHttpCacheIsSetAsATrustedProxy(array $existing, array $expected)
{
Request::setTrustedProxies($existing);
$this->setNextResponse();
$this->request('GET', '/', array('REMOTE_ADDR' => '10.0.0.1'));
$this->assertEquals($expected, Request::getTrustedProxies());
Request::setTrustedProxies(array());
} | CWE-20 | 0 |
foreach ($page as $pageperm) {
if (!empty($pageperm['manage'])) return true;
}
| CWE-74 | 1 |
public function getItems2 (
$prefix='', $page=0, $limit=20, $valueAttr='name', $nameAttr='name') {
$modelClass = get_class ($this->owner);
$model = CActiveRecord::model ($modelClass);
$table = $model->tableName ();
$offset = intval ($page) * intval ($limit);
AuxLib::coerceToArray ($valueAttr);
$modelClass::checkThrowAttrError (array_merge ($valueAttr, array ($nameAttr)));
$params = array ();
if ($prefix !== '') {
$params[':prefix'] = $prefix . '%';
}
$offset = abs ((int) $offset);
$limit = abs ((int) $limit);
$command = Yii::app()->db->createCommand ("
SELECT " . implode (',', $valueAttr) . ", $nameAttr as __name
FROM $table
WHERE " . ($prefix === '' ?
'1=1' : ($nameAttr . ' LIKE :prefix')
) . "
ORDER BY __name
LIMIT $offset, $limit
"); | CWE-20 | 0 |
public static function getStylesheet($styleName)
{
// Get custom stylesheet, of the default stylesheet if the custom stylesheet does not exist
$stylesheet = get_option($styleName, '');
if (strlen($stylesheet) <= 0)
{
$stylesheetFile = SlideshowPluginMain::getPluginPath() . DIRECTORY_SEPARATOR . 'style' . DIRECTORY_SEPARATOR . 'SlideshowPlugin' . DIRECTORY_SEPARATOR . $styleName . '.css';
if (!file_exists($stylesheetFile))
{
$stylesheetFile = SlideshowPluginMain::getPluginPath() . DIRECTORY_SEPARATOR . 'style' . DIRECTORY_SEPARATOR . 'SlideshowPlugin' . DIRECTORY_SEPARATOR . 'style-light.css';
}
// Get contents of stylesheet
ob_start();
include($stylesheetFile);
$stylesheet .= ob_get_clean();
}
// Replace the URL placeholders with actual URLs and add a unique identifier to separate stylesheets
$stylesheet = str_replace('%plugin-url%', SlideshowPluginMain::getPluginUrl(), $stylesheet);
$stylesheet = str_replace('%site-url%', get_bloginfo('url'), $stylesheet);
$stylesheet = str_replace('%stylesheet-url%', get_stylesheet_directory_uri(), $stylesheet);
$stylesheet = str_replace('%template-url%', get_template_directory_uri(), $stylesheet);
$stylesheet = str_replace('.slideshow_container', '.slideshow_container_' . $styleName, $stylesheet);
return $stylesheet;
} | CWE-200 | 10 |
public function delete_version() {
if (empty($this->params['id'])) {
flash('error', gt('The version you are trying to delete could not be found'));
}
// get the version
$version = new help_version($this->params['id']);
if (empty($version->id)) {
flash('error', gt('The version you are trying to delete could not be found'));
}
// if we have errors than lets get outta here!
if (!expQueue::isQueueEmpty('error')) expHistory::back();
// delete the version
$version->delete();
expSession::un_set('help-version');
flash('message', gt('Deleted version').' '.$version->version.' '.gt('and all documents in that version.'));
expHistory::back();
} | CWE-74 | 1 |
public static function save_uploaded_user_avatar() {
$avatar_data = wp_parse_args(
LP_Request::get( 'lp-user-avatar-crop' ),
array(
'name' => '',
'width' => '',
'height' => '',
'points' => '',
'nonce' => '',
)
);
$current_user_id = get_current_user_id();
if ( ! wp_verify_nonce( $avatar_data['nonce'], 'save-uploaded-profile-' . $current_user_id ) ) {
die( 'ERROR VERIFY NONCE!' );
}
$url = learn_press_update_user_profile_avatar();
if ( $url ) {
$user = learn_press_get_current_user();
learn_press_send_json(
array(
'success' => true,
'avatar' => sprintf( '<img src="%s" />', $url ),
)
);
};
wp_die();
} | CWE-610 | 17 |
foreach ($evs as $key=>$event) {
if ($condense) {
$eventid = $event->id;
$multiday_event = array_filter($events, create_function('$event', 'global $eventid; return $event->id === $eventid;'));
if (!empty($multiday_event)) {
unset($evs[$key]);
continue;
}
}
$evs[$key]->eventstart += $edate->date;
$evs[$key]->eventend += $edate->date;
$evs[$key]->date_id = $edate->id;
if (!empty($event->expCat)) {
$catcolor = empty($event->expCat[0]->color) ? null : trim($event->expCat[0]->color);
// if (substr($catcolor,0,1)=='#') $catcolor = '" style="color:'.$catcolor.';';
$evs[$key]->color = $catcolor;
}
}
| CWE-74 | 1 |
protected function getComment()
{
$comment = $this->commentModel->getById($this->request->getIntegerParam('comment_id'));
if (empty($comment)) {
throw new PageNotFoundException();
}
if (! $this->userSession->isAdmin() && $comment['user_id'] != $this->userSession->getId()) {
throw new AccessForbiddenException();
}
return $comment;
} | CWE-200 | 10 |
$this->markTestSkipped('Function openssl_random_pseudo_bytes need LibreSSL version >=2.1.5 or Windows system on server');
}
}
static::$functions = $functions;
// test various string lengths
for ($length = 1; $length < 64; $length++) {
$key1 = $this->security->generateRandomKey($length);
$this->assertInternalType('string', $key1);
$this->assertEquals($length, strlen($key1));
$key2 = $this->security->generateRandomKey($length);
$this->assertInternalType('string', $key2);
$this->assertEquals($length, strlen($key2));
if ($length >= 7) { // avoid random test failure, short strings are likely to collide
$this->assertNotEquals($key1, $key2);
}
}
// test for /dev/urandom, reading larger data to see if loop works properly
$length = 1024 * 1024;
$key1 = $this->security->generateRandomKey($length);
$this->assertInternalType('string', $key1);
$this->assertEquals($length, strlen($key1));
$key2 = $this->security->generateRandomKey($length);
$this->assertInternalType('string', $key2);
$this->assertEquals($length, strlen($key2));
$this->assertNotEquals($key1, $key2);
// force /dev/urandom reading loop to deal with chunked data
// the above test may have read everything in one run.
// not sure if this can happen in real life but if it does
// we should be prepared
static::$fopen = fopen('php://memory', 'rwb');
$length = 1024 * 1024;
$key1 = $this->security->generateRandomKey($length);
$this->assertInternalType('string', $key1);
$this->assertEquals($length, strlen($key1));
} | CWE-330 | 12 |
public function __construct(string $appName,
IRequest $request,
ITimeFactory $timeFactory,
IInitialState $initialState,
BookingService $bookingService,
AppointmentConfigService $appointmentConfigService,
URLGenerator $urlGenerator,
LoggerInterface $logger) {
parent::__construct($appName, $request);
$this->bookingService = $bookingService;
$this->timeFactory = $timeFactory;
$this->appointmentConfigService = $appointmentConfigService;
$this->initialState = $initialState;
$this->urlGenerator = $urlGenerator;
$this->logger = $logger;
} | CWE-77 | 14 |
public function goingForthAndBackStoresFormValuesOfSecondPageAndTriggersValidationOnlyWhenGoingForward() {
$this->browser->request('http://localhost/test/form/simpleform/ThreePageFormWithValidation');
$this->gotoNextFormPage($this->browser->getForm());
$form = $this->browser->getForm();
$form['--three-page-form-with-validation']['text2-1']->setValue('My Text on the second page');
$this->gotoPreviousFormPage($form);
$this->gotoNextFormPage($this->browser->getForm());
$r = $this->gotoNextFormPage($this->browser->getForm());
$this->assertSame(' error', $this->browser->getCrawler()->filterXPath('//*[contains(@class,"error")]//input[@id="three-page-form-with-validation-text2-1"]')->attr('class'));
$form = $this->browser->getForm();
$form['--three-page-form-with-validation']['text2-1']->setValue('42');
$this->gotoNextFormPage($form);
$form = $this->browser->getForm();
$this->assertSame('', $form['--three-page-form-with-validation']['text3-1']->getValue());
} | CWE-20 | 0 |
public function activate_address()
{
global $db, $user;
$object = new stdClass();
$object->id = $this->params['id'];
$db->setUniqueFlag($object, 'addresses', $this->params['is_what'], "user_id=" . $user->id);
flash("message", gt("Successfully updated address."));
expHistory::back();
} | CWE-74 | 1 |
function addDiscountToCart() {
// global $user, $order;
global $order;
//lookup discount to see if it's real and valid, and not already in our cart
//this will change once we allow more than one coupon code
$discount = new discounts();
$discount = $discount->getCouponByName($this->params['coupon_code']);
if (empty($discount)) {
flash('error', gt("This discount code you entered does not exist."));
//redirect_to(array('controller'=>'cart', 'action'=>'checkout'));
expHistory::back();
}
//check to see if it's in our cart already
if ($this->isDiscountInCart($discount->id)) {
flash('error', gt("This discount code is already in your cart."));
//redirect_to(array('controller'=>'cart', 'action'=>'checkout'));
expHistory::back();
}
//this should really be reworked, as it shoudn't redirect directly and not return
$validateDiscountMessage = $discount->validateDiscount();
if ($validateDiscountMessage == "") {
//if all good, add to cart, otherwise it will have redirected
$od = new order_discounts();
$od->orders_id = $order->id;
$od->discounts_id = $discount->id;
$od->coupon_code = $discount->coupon_code;
$od->title = $discount->title;
$od->body = $discount->body;
$od->save();
// set this to just the discount applied via this coupon?? if so, when though? $od->discount_total = ??;
flash('message', gt("The discount code has been applied to your cart."));
} else {
flash('error', $validateDiscountMessage);
}
//redirect_to(array('controller'=>'cart', 'action'=>'checkout'));
expHistory::back();
} | CWE-20 | 0 |
public function __construct(
AuthManager $auth,
Encrypter $encrypter,
Google2FA $google2FA,
Repository $config,
CacheRepository $cache,
RecoveryTokenRepository $recoveryTokenRepository,
UserRepositoryInterface $repository
) {
parent::__construct($auth, $config);
$this->google2FA = $google2FA;
$this->cache = $cache;
$this->repository = $repository;
$this->encrypter = $encrypter;
$this->recoveryTokenRepository = $recoveryTokenRepository;
} | CWE-287 | 4 |
public function editTitle() {
global $user;
$file = new expFile($this->params['id']);
if ($user->id==$file->poster || $user->isAdmin()) {
$file->title = $this->params['newValue'];
$file->save();
$ar = new expAjaxReply(200, gt('Your title was updated successfully'), $file);
} else {
$ar = new expAjaxReply(300, gt("You didn't create this file, so you can't edit it."));
}
$ar->send();
} | CWE-74 | 1 |
public static function restoreX2WebUser () {
if (isset (self::$_oldUserComponent)) {
Yii::app()->setComponent ('user', self::$_oldUserComponent);
} else {
throw new CException ('X2WebUser component could not be restored');
}
} | CWE-20 | 0 |
function barcode_print($code, $encoding="ANY", $scale = 2 ,$mode = "png")
{
// DOLCHANGE LDR Add log
dol_syslog("barcode.lib.php::barcode_print $code $encoding $scale $mode");
$bars=barcode_encode($code,$encoding);
if (! $bars)
{
// DOLCHANGE LDR Return error message instead of array
$error='Bad Value '.$code.' for encoding '.$encoding;
dol_syslog('barcode.lib.php::barcode_print '.$error, LOG_ERR);
return $error;
}
if (! $mode) $mode="png";
//if (preg_match("/^(text|txt|plain)$/i",$mode)) print barcode_outtext($bars['text'],$bars['bars']);
//elseif (preg_match("/^(html|htm)$/i",$mode)) print barcode_outhtml($bars['text'],$bars['bars'], $scale,0, 0);
//else
barcode_outimage($bars['text'], $bars['bars'], $scale, $mode);
return $bars;
} | CWE-20 | 0 |
->where('owned_by', '=', $userIdToCheck);
});
} | CWE-863 | 11 |
public function testRedirectLinkGeneration () {
Yii::app()->controller = new MarketingController (
'campaign', new MarketingModule ('campaign', null));
$_SERVER['SERVER_NAME'] = 'localhost';
$cmb = $this->instantiate();
$contact = $this->contacts('testUser_unsent');
$campaign = $this->campaign('redirectLinkGeneration');
$url = preg_replace ('/^[^"]*"([^"]*)".*$/', '$1', $campaign->content);
list($subject,$message,$uniqueId) = $cmb->prepareEmail(
$this->campaign('redirectLinkGeneration'),
$contact,$this->listItem('testUser_unsent')->emailAddress);
$this->assertRegExp ('/'.preg_quote (urlencode ($url)).'/', $message);
} | CWE-20 | 0 |
$cols = explode( '}:', $label );
if ( count( $cols ) <= 1 ) {
if ( array_key_exists( $t, $_tableRow ) ) {
$tableRow[$groupNr] = $_tableRow[$t];
}
} else {
$n = count( explode( ':', $cols[1] ) );
$colNr = -1;
$t--;
for ( $i = 1; $i <= $n; $i++ ) {
$colNr++;
$t++;
if ( array_key_exists( $t, $_tableRow ) ) {
$tableRow[$groupNr . '.' . $colNr] = $_tableRow[$t];
}
}
}
}
return $tableRow;
} | CWE-400 | 2 |
private function _notlastmodifiedby( $option ) {
$user = new \User;
$this->addWhere( $this->DB->addQuotes( $user->newFromName( $option )->getActorId() ) . ' != (SELECT revactor_actor FROM ' . $this->tableNames['revision_actor_temp'] . ' WHERE ' . $this->tableNames['revision_actor_temp'] . '.revactor_page=page_id ORDER BY ' . $this->tableNames['revision_actor_temp'] . '.revactor_timestamp DESC LIMIT 1)' );
} | CWE-400 | 2 |
public function testESIHeaderIsKeptInSubrequest()
{
$expectedSubRequest = Request::create('/');
$expectedSubRequest->headers->set('Surrogate-Capability', 'abc="ESI/1.0"');
if (Request::getTrustedHeaderName(Request::HEADER_CLIENT_IP)) {
$expectedSubRequest->headers->set('x-forwarded-for', array('127.0.0.1'));
$expectedSubRequest->server->set('HTTP_X_FORWARDED_FOR', '127.0.0.1');
}
$strategy = new InlineFragmentRenderer($this->getKernelExpectingRequest($expectedSubRequest));
$request = Request::create('/');
$request->headers->set('Surrogate-Capability', 'abc="ESI/1.0"');
$strategy->render('/', $request);
} | CWE-20 | 0 |
static public function getInstanceOf($_usernfo, $_tid) {
if (!isset(self::$tickets[$_tid])) {
self::$tickets[$_tid] = new ticket($_usernfo, $_tid);
}
return self::$tickets[$_tid];
} | CWE-732 | 13 |
function edit() {
global $template;
parent::edit();
$allforms = array();
$allforms[""] = gt('Disallow Feedback');
// calculate which event date is the one being edited
$event_key = 0;
foreach ($template->tpl->tpl_vars['record']->value->eventdate as $key=>$d) {
if ($d->id == $this->params['date_id']) $event_key = $key;
}
assign_to_template(array(
'allforms' => array_merge($allforms, expTemplate::buildNameList("forms", "event/email", "tpl", "[!_]*")),
'checked_date' => !empty($this->params['date_id']) ? $this->params['date_id'] : null,
'event_key' => $event_key,
));
}
| CWE-74 | 1 |
$files[$key]->save();
}
// eDebug($files,true);
} | CWE-74 | 1 |
private function isWindows()
{
return DIRECTORY_SEPARATOR !== '/';
} | CWE-330 | 12 |
mxDualRuler.prototype.setUnit=function(b){this.vRuler.setUnit(b);this.hRuler.setUnit(b)};mxDualRuler.prototype.setStyle=function(b){this.vRuler.setStyle(b);this.hRuler.setStyle(b)};mxDualRuler.prototype.destroy=function(){this.vRuler.destroy();this.hRuler.destroy();this.ui.refresh=this.editorUiRefresh;mxGuide.prototype.move=this.origGuideMove;mxGuide.prototype.destroy=this.origGuideDestroy;this.ui.getDiagramContainerOffset=this.editorUiGetDiagContOffset};function mxFreehand(b){var f=null!=b.view&&null!=b.view.canvas?b.view.canvas.ownerSVGElement:null;if(null!=b.container&&null!=f){b.addListener(mxEvent.ESCAPE,mxUtils.bind(this,function(){this.stopDrawing()}));var l=mxFreehand.prototype.NORMAL_SMOOTHING,d=null,u=[],t,D=[],c,e=!1,g=!0,k=!0,m=!0,q=!0,v=[],x=!1,A=!0,z=!1,L={size:12,thinning:.5,smoothing:.5,streamline:.5,start:{taper:0,cap:!0},end:{taper:0,cap:!0}},M=!1;this.setClosedPath=function(J){e=J};this.setAutoClose=function(J){g=J};this.setAutoInsert= | CWE-20 | 0 |
stringEscapeFn: function(c) {
return '\\u' + ('0000' + c.charCodeAt(0).toString(16)).slice(-4);
}, | CWE-74 | 1 |
D;var E=y(".odPreview"),J=y("#odFiles");b=function(N,Q){Q=Q||document;return Q.querySelectorAll(N)}(".odCatListTitle");for(D=0;D<b.length;D++)b[D].addEventListener("click",function(){H=U=null;if(!V)switch(L(this),this.id){case "odFiles":z();break;case "odRecent":z("recent");break;case "odShared":z("shared");break;case "odSharepoint":z("sharepoint")}});var T=null;y("#odSearchBox").addEventListener("keyup",function(N){var Q=this;null!=T&&clearTimeout(T);13==N.keyCode?C(Q.value):T=setTimeout(function(){C(Q.value)}, | CWE-20 | 0 |
function(u,E,J,T,N,Q,R,Y,ba,ea){if(null!=J&&null==mxMarker.markers[J]){var Z=this.getPackageForType(J);null!=Z&&mxStencilRegistry.getStencil(Z)}return V.apply(this,arguments)};var M=mxStencil.prototype.drawShape;mxStencil.prototype.drawShape=function(u,E,J,T,N,Q){"1"==mxUtils.getValue(E.style,"lineShape",null)&&u.setFillColor(mxUtils.getValue(E.style,mxConstants.STYLE_STROKECOLOR,this.stroke));return M.apply(this,arguments)};PrintDialog.prototype.create=function(u,E){function J(){aa.value=Math.max(1,
Math.min(Y,Math.max(parseInt(aa.value),parseInt(fa.value))));fa.value=Math.max(1,Math.min(Y,Math.min(parseInt(aa.value),parseInt(fa.value))))}function T(ya){function wa(Ja,Oa,Pa){var Qa=Ja.useCssTransforms,Ya=Ja.currentTranslate,Ma=Ja.currentScale,Ta=Ja.view.translate,Ua=Ja.view.scale;Ja.useCssTransforms&&(Ja.useCssTransforms=!1,Ja.currentTranslate=new mxPoint(0,0),Ja.currentScale=1,Ja.view.translate=new mxPoint(0,0),Ja.view.scale=1);var Za=Ja.getGraphBounds(),Wa=0,bb=0,Va=oa.get(),ab=1/Ja.pageScale, | CWE-20 | 0 |
this.unitListener=function(n,y){g.setUnit(y.getProperty("unit"))};x.addListener(mxEvent.SIZE,f);x.container.addEventListener("scroll",d);x.view.addListener("unitChanged",this.unitListener);b.addListener("pageViewChanged",this.pageListener);b.addListener("pageScaleChanged",this.pageListener);b.addListener("pageFormatChanged",this.pageListener);this.setStyle=function(n){k=n;m.style.background=k.bkgClr;z()};this.origGuideMove=mxGuide.prototype.move;mxGuide.prototype.move=function(n,y,K,B){if(l&&4<n.height|| | CWE-20 | 0 |
function tileLevel(inPath, outPath, zoom, tileSize, pattern, quality) {
var dotExtension = pattern.replace(/.*(\.[^.]+)$/, '$1');
var patternedFilename = pattern.replace(/\{z\}/, '' + zoom)
.replace(/\{x\}/, '%[fx:page.x/' + tileSize + ']')
.replace(/\{y\}/, '%[fx:page.y/' + tileSize + ']')
.replace(/\.[^.]+$/, '');
var patternedFilenameWithoutTheFilename = '';
if (pattern.indexOf(path.sep) > 0) {
patternedFilenameWithoutTheFilename = pattern.replace(new RegExp(path.sep+'[^'+path.sep+']*$'), '')
.replace(/\{z\}/, '' + zoom);
}
return mkdirp(outPath + path.sep + patternedFilenameWithoutTheFilename)
.then(()=>{
var command = 'convert ' + inPath +
' -crop ' + tileSize + 'x' + tileSize +
' -set filename:tile "' + patternedFilename + '"' +
' -quality ' + quality + ' +repage +adjoin' +
' "' + outPath + '/%[filename:tile]' + dotExtension + '"' ;
execSync(command);
});
} | CWE-77 | 14 |
current: function() {
return this.state[this.state.computing];
} | CWE-74 | 1 |
function(n){g.editorUiRefresh.apply(b,arguments);u()};u();var q=document.createElement("canvas");q.width=m.offsetWidth;q.height=m.offsetHeight;m.style.overflow="hidden";q.style.position="relative";m.appendChild(q);var v=q.getContext("2d");this.ui=b;var x=b.editor.graph;this.graph=x;this.container=m;this.canvas=q;var A=function(n,y,K,B,F){n=Math.round(n);y=Math.round(y);K=Math.round(K);B=Math.round(B);v.beginPath();v.moveTo(n+.5,y+.5);v.lineTo(K+.5,B+.5);v.stroke();F&&(l?(v.save(),v.translate(n,y),
v.rotate(-Math.PI/2),v.fillText(F,0,0),v.restore()):v.fillText(F,n,y))},z=function(){v.clearRect(0,0,q.width,q.height);v.beginPath();v.lineWidth=.7;v.strokeStyle=k.strokeClr;v.setLineDash([]);v.font="9px Arial";v.textAlign="center";var n=x.view.scale,y=x.view.getBackgroundPageBounds(),K=x.view.translate,B=x.pageVisible;K=B?e+(l?y.y-x.container.scrollTop:y.x-x.container.scrollLeft):e+(l?K.y*n-x.container.scrollTop:K.x*n-x.container.scrollLeft);var F=0;B&&(F=x.getPageLayout(),F=l?F.y*x.pageFormat.height: | CWE-20 | 0 |
var T=document.createElement("tbody"),P=(new Date).toDateString();null!=b.currentPage&&null!=b.pages&&(e=mxUtils.indexOf(b.pages,b.currentPage));for(q=f.length-1;0<=q;q--){var O=function(R){var Y=new Date(R.modifiedDate),da=null;if(0<=Y.getTime()){var ha=function(ea){v.stop();D.innerHTML="";var aa=mxUtils.parseXml(ea),ua=b.editor.extractGraphModel(aa.documentElement,!0);if(null!=ua){var la=function(Fa){null!=Fa&&(Fa=Aa(Editor.parseDiagramNode(Fa)));return Fa},Aa=function(Fa){var xa=Fa.getAttribute("background"); | CWE-20 | 0 |
e},ConnectionPointsDialog=function(b,e){function f(){null!=m&&m.destroy()}var c=document.createElement("div");c.style.userSelect="none";var m=null;this.init=function(){function n(F,H){F=new mxCell("",new mxGeometry(F,H,6,6),"shape=mxgraph.basic.x;fillColor=#29b6f2;strokeColor=#29b6f2;points=[];rotatable=0;resizable=0;connectable=0;editable=0;");F.vertex=!0;F.cp=!0;return p.addCell(F)}function v(F){F=p.getSelectionCells();p.deleteCells(F)}function d(){var F=parseInt(D.value)||0;F=0>F?0:100<F?100:F; | CWE-20 | 0 |
this.defaultFilename,!0);g.getHash=function(){return b};this.fileLoaded(g);null!=d&&d()}else if("E"==b.charAt(0))null==this.getCurrentFile()?this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")},mxResources.get("errorLoadingFile")):this.remoteInvoke("getDraftFileContent",null,null,mxUtils.bind(this,function(v,x){this.spinner.stop();this.fileLoaded(new EmbedFile(this,v,x));null!=d&&d()}),mxUtils.bind(this,function(){this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")}, | CWE-20 | 0 |
function isPromiseLike(obj) {
return obj && isFunction(obj.then);
} | CWE-74 | 1 |
Za.decode(Ma,Wa);Ma=Wa.root.getChildAt(0).children;b.sidebar.createTooltip(na,Ma,Math.min((window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)-80,1E3),Math.min((window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight)-80,800),null!=ya?mxResources.get(ya,null,ya):null,!0,new mxPoint(Ta,Ua),!0,function(){Ya=null!=b.sidebar.tooltip&&"none"!=b.sidebar.tooltip.style.display;z(na,null,null,oa,ha,ia)},!0,!1)}}function pa(Ma,Ta){null==oa||Ra||
b.sidebar.currentElt==na?b.sidebar.hideTooltip():(b.sidebar.hideTooltip(),null!=Sa?(Ta='<mxfile><diagram id="d" name="n">'+Graph.compress('<mxGraphModel><root><mxCell id="0"/><mxCell id="1" parent="0"/><mxCell id="2" value="" style="shape=image;image='+Sa.src+';imageAspect=1;" parent="1" vertex="1"><mxGeometry width="'+Sa.naturalWidth+'" height="'+Sa.naturalHeight+'" as="geometry" /></mxCell></root></mxGraphModel>')+"</diagram></mxfile>",qa(Ta,mxEvent.getClientX(Ma),mxEvent.getClientY(Ma))):(b.sidebar.currentElt=
na,Ra=!0,ma(oa,function(Ua){Ra&&b.sidebar.currentElt==na&&qa(Ua,mxEvent.getClientX(Ma),mxEvent.getClientY(Ma));Ra=!1})))}var na=document.createElement("div");na.className="geTemplate";na.style.position="relative";na.style.height=Ha+"px";na.style.width=ra+"px";var Ka=null,Ia=oa;Editor.isDarkMode()&&(na.style.filter="invert(100%)");null!=ya?na.setAttribute("title",mxResources.get(ya,null,ya)):null!=wa&&0<wa.length&&na.setAttribute("title",wa);var Ra=!1,Sa=null;if(null!=xa){na.style.display="inline-flex"; | CWE-20 | 0 |
noUnsafeEval: noUnsafeEval(),
noInlineStyle: false
};
}
} | CWE-74 | 1 |
S&&S(M)}}))}catch(L){null!=S&&S(L)}}),N,sa)}catch(Pa){null!=S&&S(Pa)}};Editor.crcTable=[];for(var D=0;256>D;D++)for(var t=D,F=0;8>F;F++)t=1==(t&1)?3988292384^t>>>1:t>>>1,Editor.crcTable[D]=t;Editor.updateCRC=function(u,J,N,W){for(var S=0;S<W;S++)u=Editor.crcTable[(u^J.charCodeAt(N+S))&255]^u>>>8;return u};Editor.crc32=function(u){for(var J=-1,N=0;N<u.length;N++)J=J>>>8^Editor.crcTable[(J^u.charCodeAt(N))&255];return(J^-1)>>>0};Editor.writeGraphModelToPng=function(u,J,N,W,S){function P(sa,Ba){var ta= | CWE-20 | 0 |
function u(){mxShape.call(this)}function J(){mxShape.call(this)}function N(){mxRectangleShape.call(this)}function W(){mxShape.call(this)}function S(){mxShape.call(this)}function P(){mxShape.call(this)}function Z(){mxShape.call(this)}function oa(){mxShape.call(this)}function va(){mxCylinder.call(this)}function Aa(){mxCylinder.call(this)}function sa(){mxRectangleShape.call(this)}function Ba(){mxDoubleEllipse.call(this)}function ta(){mxDoubleEllipse.call(this)}function Na(){mxArrowConnector.call(this);
this.spacing=0}function Ca(){mxArrowConnector.call(this);this.spacing=0}function Ra(){mxActor.call(this)}function ab(){mxRectangleShape.call(this)}function Ka(){mxActor.call(this)}function bb(){mxActor.call(this)}function Pa(){mxActor.call(this)}function Za(){mxActor.call(this)}function z(){mxActor.call(this)}function L(){mxActor.call(this)}function M(){mxActor.call(this)}function T(){mxActor.call(this)}function ca(){mxActor.call(this)}function ia(){mxActor.call(this)}function ma(){mxEllipse.call(this)} | CWE-20 | 0 |
this.customFonts)))}finally{V.getModel().endUpdate()}}}));this.editorUi.showDialog(W.container,380,Editor.enableWebFonts?250:180,!0,!0);W.init()}),z,null,!0)})))}})();function DiagramPage(b,e){this.node=b;null!=e?this.node.setAttribute("id",e):null==this.getId()&&this.node.setAttribute("id",Editor.guid())}DiagramPage.prototype.node=null;DiagramPage.prototype.root=null;DiagramPage.prototype.viewState=null;DiagramPage.prototype.getId=function(){return this.node.getAttribute("id")};DiagramPage.prototype.getName=function(){return this.node.getAttribute("name")}; | CWE-20 | 0 |
inputs: function(input, watchId) {
return function(scope, value, locals, inputs) {
if (inputs) return inputs[watchId];
return input(scope, value, locals);
};
} | CWE-74 | 1 |
this.spacing=0}function Ca(){mxArrowConnector.call(this);this.spacing=0}function Ra(){mxActor.call(this)}function ab(){mxRectangleShape.call(this)}function Ka(){mxActor.call(this)}function bb(){mxActor.call(this)}function Pa(){mxActor.call(this)}function Za(){mxActor.call(this)}function z(){mxActor.call(this)}function L(){mxActor.call(this)}function M(){mxActor.call(this)}function T(){mxActor.call(this)}function ca(){mxActor.call(this)}function ia(){mxActor.call(this)}function ma(){mxEllipse.call(this)} | CWE-20 | 0 |
var CommentsWindow=function(b,e,f,c,m,n){function v(){for(var K=O.getElementsByTagName("div"),F=0,H=0;H<K.length;H++)"none"!=K[H].style.display&&K[H].parentNode==O&&F++;t.style.display=0==F?"block":"none"}function d(K,F,H,S){function V(){F.removeChild(U);F.removeChild(X);W.style.display="block";M.style.display="block"}A={div:F,comment:K,saveCallback:H,deleteOnCancel:S};var M=F.querySelector(".geCommentTxt"),W=F.querySelector(".geCommentActionsList"),U=document.createElement("textarea");U.className= | CWE-20 | 0 |
F.createStatusContainer();F.statusContainer.style.position="relative";F.statusContainer.style.maxWidth="";F.statusContainer.style.marginTop="7px";F.statusContainer.style.marginLeft="6px";F.statusContainer.style.color="gray";F.statusContainer.style.cursor="default";var W=F.hideCurrentMenu;F.hideCurrentMenu=function(){W.apply(this,arguments);this.editor.graph.popupMenuHandler.hideMenu()};var U=F.descriptorChanged;F.descriptorChanged=function(){U.apply(this,arguments);var da=F.getCurrentFile();if(null!=
da&&null!=da.getTitle()){var ca=da.getMode();"google"==ca?ca="googleDrive":"github"==ca?ca="gitHub":"gitlab"==ca?ca="gitLab":"onedrive"==ca&&(ca="oneDrive");ca=mxResources.get(ca);S.setAttribute("title",da.getTitle()+(null!=ca?" ("+ca+")":""))}else S.removeAttribute("title")};F.setStatusText(F.editor.getStatus());S.appendChild(F.statusContainer);F.buttonContainer=document.createElement("div");F.buttonContainer.style.cssText="position:absolute;right:0px;padding-right:34px;top:10px;white-space:nowrap;padding-top:2px;background-color:inherit;"; | CWE-20 | 0 |
return this.editor.exportToCanvas(c,e,g,k,m,q,v,x,A,z,L,M,n,y,K,B)};EditorUi.prototype.createImageUrlConverter=function(){EditorUi.logEvent("SHOULD NOT BE CALLED: createImageUrlConverter");return this.editor.createImageUrlConverter()};EditorUi.prototype.convertImages=function(c,e,g,k){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImages");return this.editor.convertImages(c,e,g,k)};EditorUi.prototype.convertImageToDataUri=function(c,e){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImageToDataUri");
return this.editor.convertImageToDataUri(c,e)};EditorUi.prototype.base64Encode=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: base64Encode");return Editor.base64Encode(c)};EditorUi.prototype.updateCRC=function(c,e,g,k){EditorUi.logEvent("SHOULD NOT BE CALLED: updateCRC");return Editor.updateCRC(c,e,g,k)};EditorUi.prototype.crc32=function(c){EditorUi.logEvent("SHOULD NOT BE CALLED: crc32");return Editor.crc32(c)};EditorUi.prototype.writeGraphModelToPng=function(c,e,g,k,m){EditorUi.logEvent("SHOULD NOT BE CALLED: writeGraphModelToPng"); | CWE-20 | 0 |
document.createElement("tr");ja.className="gePropHeader";var Ba=document.createElement("th");Ba.className="gePropHeaderCell";var Ha=document.createElement("img");Ha.src=Sidebar.prototype.expandedImage;Ha.style.verticalAlign="middle";Ba.appendChild(Ha);mxUtils.write(Ba,mxResources.get("property"));ja.style.cursor="pointer";var ra=function(){var Aa=va.querySelectorAll(".gePropNonHeaderRow");if(Z.editorUi.propertiesCollapsed){Ha.src=Sidebar.prototype.collapsedImage;var ta="none";for(var ka=u.childNodes.length-
1;0<=ka;ka--)try{var oa=u.childNodes[ka],sa=oa.nodeName.toUpperCase();"INPUT"!=sa&&"SELECT"!=sa||u.removeChild(oa)}catch(ya){}}else Ha.src=Sidebar.prototype.expandedImage,ta="";for(ka=0;ka<Aa.length;ka++)Aa[ka].style.display=ta};mxEvent.addListener(ja,"click",function(){Z.editorUi.propertiesCollapsed=!Z.editorUi.propertiesCollapsed;ra()});ja.appendChild(Ba);Ba=document.createElement("th");Ba.className="gePropHeaderCell";Ba.innerHTML=mxResources.get("value");ja.appendChild(Ba);va.appendChild(ja);var Ca= | CWE-20 | 0 |
function pa(){mxEllipse.call(this)}function ua(){mxEllipse.call(this)}function ya(){mxRhombus.call(this)}function Fa(){mxEllipse.call(this)}function Ma(){mxEllipse.call(this)}function Oa(){mxEllipse.call(this)}function Qa(){mxEllipse.call(this)}function Ta(){mxActor.call(this)}function za(){mxActor.call(this)}function wa(){mxActor.call(this)}function Ea(c,l,x,p){mxShape.call(this);this.bounds=c;this.fill=l;this.stroke=x;this.strokewidth=null!=p?p:1;this.rectStyle="square";this.size=10;this.absoluteCornerSize= | CWE-20 | 0 |
function isBoolean(value) {
return typeof value === 'boolean';
} | CWE-74 | 1 |
d.addHours=function(a,c){return d.addMinutes(a,60*c)};d.addMinutes=function(a,c){return d.addSeconds(a,60*c)};d.addSeconds=function(a,c){return d.addMilliseconds(a,1E3*c)};d.addMilliseconds=function(a,c){return new Date(a.getTime()+c)};d.subtract=function(a,c){var b=a.getTime()-c.getTime();return{toMilliseconds:function(){return b},toSeconds:function(){return b/1E3},toMinutes:function(){return b/6E4},toHours:function(){return b/36E5},toDays:function(){return b/864E5}}};d.isLeapYear=function(a){return!(a% | CWE-400 | 2 |
this.graph.isMouseDown=!0;x.hoverIcons.reset();mxEvent.consume(H)})))};var P=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){P.apply(this,arguments);null!=this.moveHandle&&(this.moveHandle.style.left=this.state.x+this.state.width+(40>this.state.width?10:0)+2+"px",this.moveHandle.style.top=this.state.y+this.state.height+(40>this.state.height?10:0)+2+"px")};var K=mxVertexHandler.prototype.setHandlesVisible;mxVertexHandler.prototype.setHandlesVisible=function(H){K.apply(this,
arguments);null!=this.moveHandle&&(this.moveHandle.style.display=H?"":"none")};var F=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=function(H,S){F.apply(this,arguments);null!=this.moveHandle&&(this.moveHandle.parentNode.removeChild(this.moveHandle),this.moveHandle=null)}};if("undefined"!==typeof Sidebar){var f=Sidebar.prototype.createAdvancedShapes;Sidebar.prototype.createAdvancedShapes=function(){var c=f.apply(this,arguments),m=this.graph;return c.concat([this.addEntry("tree container", | CWE-20 | 0 |
this.put("editCell",new Menu(mxUtils.bind(this,function(R,fa){var la=this.editorUi.editor.graph,ra=la.getSelectionCell();ka.call(this,R,ra,null,fa);this.addMenuItems(R,["editTooltip"],fa);la.model.isVertex(ra)&&this.addMenuItems(R,["editGeometry"],fa);this.addMenuItems(R,["-","edit"],fa)})));this.addPopupMenuCellEditItems=function(R,fa,la,ra){R.addSeparator();this.addSubmenu("editCell",R,ra,mxResources.get("edit"))};this.put("file",new Menu(mxUtils.bind(this,function(R,fa){var la=O.getCurrentFile(); | CWE-20 | 0 |
this.window.setLocation(q,v)});mxEvent.addListener(window,"resize",m);this.destroy=function(){mxEvent.removeListener(window,"resize",m);this.window.destroy()}},TagsWindow=function(b,f,l,d,u){var t=b.editor.graph,D=b.editor.graph.createTagsDialog(mxUtils.bind(this,function(){return this.window.isVisible()}),null,function(g,k){if(t.isEnabled()){var m=new FilenameDialog(b,"",mxResources.get("add"),function(q){b.hideDialog();if(null!=q&&0<q.length){q=q.split(" ");for(var v=[],x=0;x<q.length;x++){var A= | CWE-20 | 0 |
Ra=document.createElement("div");Ra.className="geTempDlgDiagramTileImg geTempDlgDiagramTileImgLoading";var Qa=document.createElement("img");Qa.style.display="none";(function(La,Ta,Ua){Qa.onload=function(){Ta.className="geTempDlgDiagramTileImg";La.style.display=""};Qa.onerror=function(){this.src!=Ua?this.src=Ua:Ta.className="geTempDlgDiagramTileImg geTempDlgDiagramTileImgError"}})(Qa,Ra,Ga?Ga.replace(".drawio.xml","").replace(".drawio","").replace(".xml",""):"");Qa.src=Ga;Ra.appendChild(Qa);Pa.appendChild(Ra); | CWE-20 | 0 |
d.addHours=function(a,c){return d.addMinutes(a,60*c)};d.addMinutes=function(a,c){return d.addSeconds(a,60*c)};d.addSeconds=function(a,c){return d.addMilliseconds(a,1E3*c)};d.addMilliseconds=function(a,c){return new Date(a.getTime()+c)};d.subtract=function(a,c){var b=a.getTime()-c.getTime();return{toMilliseconds:function(){return b},toSeconds:function(){return b/1E3},toMinutes:function(){return b/6E4},toHours:function(){return b/36E5},toDays:function(){return b/864E5}}};d.isLeapYear=function(a){return!(a% | CWE-400 | 2 |
p-A,ha);c.lineTo(l+p-B-A,ha+B/2);c.end();c.stroke()};mxCellRenderer.registerShape("dimension",Ma);mxUtils.extend(Oa,mxEllipse);Oa.prototype.drawHidden=!0;Oa.prototype.paintVertexShape=function(c,l,x,p,v){this.outline||c.setStrokeColor(null);if(null!=this.style){var A=c.pointerEvents,B=null!=this.fill&&this.fill!=mxConstants.NONE;"1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1")||B||(c.pointerEvents=!1);var ha="1"==mxUtils.getValue(this.style,"top","1"),K="1"==mxUtils.getValue(this.style,
"left","1"),xa="1"==mxUtils.getValue(this.style,"right","1"),na="1"==mxUtils.getValue(this.style,"bottom","1");this.drawHidden||B||this.outline||ha||xa||na||K?(c.rect(l,x,p,v),c.fill(),c.pointerEvents=A,c.setStrokeColor(this.stroke),c.setLineCap("square"),c.begin(),c.moveTo(l,x),this.outline||ha?c.lineTo(l+p,x):c.moveTo(l+p,x),this.outline||xa?c.lineTo(l+p,x+v):c.moveTo(l+p,x+v),this.outline||na?c.lineTo(l,x+v):c.moveTo(l,x+v),(this.outline||K)&&c.lineTo(l,x),c.end(),c.stroke(),c.setLineCap("flat")):
c.setStrokeColor(this.stroke)}};mxCellRenderer.registerShape("partialRectangle",Oa);mxUtils.extend(Qa,mxEllipse);Qa.prototype.paintVertexShape=function(c,l,x,p,v){mxEllipse.prototype.paintVertexShape.apply(this,arguments);c.setShadow(!1);c.begin();"vertical"==mxUtils.getValue(this.style,"line")?(c.moveTo(l+p/2,x),c.lineTo(l+p/2,x+v)):(c.moveTo(l,x+v/2),c.lineTo(l+p,x+v/2));c.end();c.stroke()};mxCellRenderer.registerShape("lineEllipse",Qa);mxUtils.extend(Ta,mxActor);Ta.prototype.redrawPath=function(c, | CWE-20 | 0 |
d.addHours=function(a,c){return d.addMinutes(a,60*c)};d.addMinutes=function(a,c){return d.addSeconds(a,60*c)};d.addSeconds=function(a,c){return d.addMilliseconds(a,1E3*c)};d.addMilliseconds=function(a,c){return new Date(a.getTime()+c)};d.subtract=function(a,c){var b=a.getTime()-c.getTime();return{toMilliseconds:function(){return b},toSeconds:function(){return b/1E3},toMinutes:function(){return b/6E4},toHours:function(){return b/36E5},toDays:function(){return b/864E5}}};d.isLeapYear=function(a){return!(a% | CWE-400 | 2 |
index:J,defVal:ja.defVal,countProperty:ja.countProperty,size:ja.size},0==J%2,ja.flipBkg),E.parentNode.insertBefore(Ga,E.nextSibling),E=Ga;u.appendChild(va);ra();return u};StyleFormatPanel.prototype.addStyles=function(u){function E(ja){mxEvent.addListener(ja,"mouseenter",function(){ja.style.opacity="1"});mxEvent.addListener(ja,"mouseleave",function(){ja.style.opacity="0.5"})}var J=this.editorUi,T=J.editor.graph,N=document.createElement("div");N.style.whiteSpace="nowrap";N.style.paddingLeft="24px"; | CWE-20 | 0 |
t.toDataURL();if(z.length<g.length){var L=document.createElement("canvas");L.width=I;L.height=O;var C=L.toDataURL();z!==C&&(g=z,y=I,A=O)}}}catch(D){}k(g,y,A)};EditorUi.prototype.extractGraphModelFromPng=function(d){return Editor.extractGraphModelFromPng(d)};EditorUi.prototype.loadImage=function(d,g,k){try{var l=new Image;l.onload=function(){l.width=0<l.width?l.width:120;l.height=0<l.height?l.height:120;g(l)};null!=k&&(l.onerror=k);l.src=d}catch(p){if(null!=k)k(p);else throw p;}};EditorUi.prototype.getDefaultSketchMode= | CWE-20 | 0 |
J&&E(Editor.svgBrokenImage.src)});else{var N=new Image;this.crossOriginImages&&(N.crossOrigin="anonymous");N.onload=function(){window.clearTimeout(T);if(J)try{var Q=document.createElement("canvas"),R=Q.getContext("2d");Q.height=N.height;Q.width=N.width;R.drawImage(N,0,0);E(Q.toDataURL())}catch(Y){E(Editor.svgBrokenImage.src)}};N.onerror=function(){window.clearTimeout(T);J&&E(Editor.svgBrokenImage.src)};N.src=u}}catch(Q){E(Editor.svgBrokenImage.src)}};Editor.prototype.convertImages=function(u,E,J,
T){null==T&&(T=this.createImageUrlConverter());var N=0,Q=J||{};J=mxUtils.bind(this,function(R,Y){R=u.getElementsByTagName(R);for(var ba=0;ba<R.length;ba++)mxUtils.bind(this,function(ea){try{if(null!=ea){var Z=T.convert(ea.getAttribute(Y));if(null!=Z&&"data:"!=Z.substring(0,5)){var fa=Q[Z];null==fa?(N++,this.convertImageToDataUri(Z,function(aa){null!=aa&&(Q[Z]=aa,ea.setAttribute(Y,aa));N--;0==N&&E(u)})):ea.setAttribute(Y,fa)}else null!=Z&&ea.setAttribute(Y,Z)}}catch(aa){}})(R[ba])});J("image","xlink:href");
J("img","src");0==N&&E(u)};Editor.base64Encode=function(u){for(var E="",J=0,T=u.length,N,Q,R;J<T;){N=u.charCodeAt(J++)&255;if(J==T){E+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(N>>2);E+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((N&3)<<4);E+="==";break}Q=u.charCodeAt(J++);if(J==T){E+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(N>>2);E+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((N& | CWE-20 | 0 |
l.isRemoteFileFormat(B,d.name)?l.isOffline()?l.showError(mxResources.get("error"),mxResources.get("notInOffline"),null,k):l.parseFileData(B,mxUtils.bind(this,function(I){4==I.readyState&&(200<=I.status&&299>=I.status?g(I.responseText):k())}),d.name):k()}):A||k()}},function(q){k(q)}):k()});"undefined"!==typeof JSZip||this.loadingExtensions||this.isOffline(!0)?p():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",p))};EditorUi.prototype.importFile=function(d,g,k,l,p,q,x,y,A,B,I,O){B=null!=
B?B:!0;var t=!1,z=null,L=mxUtils.bind(this,function(C){var D=null;null!=C&&"<mxlibrary"==C.substring(0,10)?this.loadLibrary(new LocalLibrary(this,C,x)):D=this.importXml(C,k,l,B,null,null!=O?mxEvent.isControlDown(O):null);null!=y&&y(D)});"image"==g.substring(0,5)?(A=!1,"image/png"==g.substring(0,9)&&(g=I?null:this.extractGraphModelFromPng(d),null!=g&&0<g.length&&(z=this.importXml(g,k,l,B,null,null!=O?mxEvent.isControlDown(O):null),A=!0)),A||(g=this.editor.graph,A=d.indexOf(";"),0<A&&(d=d.substring(0,
A)+d.substring(d.indexOf(",",A+1))),B&&g.isGridEnabled()&&(k=g.snap(k),l=g.snap(l)),z=[g.insertVertex(null,null,"",k,l,p,q,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=default;verticalAlign=top;aspect=fixed;imageAspect=0;image="+d+";")])):/(\.*<graphml )/.test(d)?(t=!0,this.importGraphML(d,L)):null!=A&&null!=x&&(/(\.v(dx|sdx?))($|\?)/i.test(x)||/(\.vs(x|sx?))($|\?)/i.test(x))?(t=!0,this.importVisio(A,L)):(new XMLHttpRequest).upload&&this.isRemoteFileFormat(d,x)?this.isOffline()? | CWE-20 | 0 |
DotObject.prototype.transfer = function (source, target, obj1, obj2, mods, merge) {
if (typeof mods === 'function' || Array.isArray(mods)) {
this.set(target,
_process(
this.pick(source, obj1, true),
mods
), obj2, merge)
} else {
merge = mods
this.set(target, this.pick(source, obj1, true), obj2, merge)
}
return obj2
} | CWE-74 | 1 |
function(q){q&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()}));c.init()};var l=EditorUi.prototype.createFormat;EditorUi.prototype.createFormat=function(c){var e=l.apply(this,arguments);this.editor.graph.addListener("viewStateChanged",mxUtils.bind(this,function(g){this.editor.graph.isSelectionEmpty()&&e.refresh()}));return e};EditorUi.prototype.createSidebarFooterContainer=function(){var c=this.createDiv("geSidebarContainer geSidebarFooter");c.style.position="absolute";c.style.overflow=
"hidden";var e=document.createElement("a");e.className="geTitle";e.style.color="#DF6C0C";e.style.fontWeight="bold";e.style.height="100%";e.style.paddingTop="9px";e.innerHTML="<span>+</span>";var g=e.getElementsByTagName("span")[0];g.style.fontSize="18px";g.style.marginRight="5px";mxUtils.write(e,mxResources.get("moreShapes")+"...");mxEvent.addListener(e,mxClient.IS_POINTER?"pointerdown":"mousedown",mxUtils.bind(this,function(k){k.preventDefault()}));mxEvent.addListener(e,"click",mxUtils.bind(this,
function(k){this.actions.get("shapes").funct();mxEvent.consume(k)}));c.appendChild(e);return c};EditorUi.prototype.handleError=function(c,e,g,k,m,q,v){var x=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},A=null!=c&&null!=c.error?c.error:c;if(null!=c&&("1"==urlParams.test||null!=c.stack)&&null!=c.message)try{v?null!=window.console&&console.error("EditorUi.handleError:",c):EditorUi.logError("Caught: "+(""==c.message&&null!=c.name)?c.name:c.message,c.filename,c.lineNumber, | CWE-20 | 0 |
self._getForwarded = function(message) {
try {
var forwarded_message = $(message.getNode()).find('forwarded[xmlns="' + NS_URN_FORWARD + '"]:first message:first');
if(forwarded_message[0]) {
return JSJaCPacket.wrapNode(forwarded_message[0]);
}
return null;
} catch(e) {
Console.error('Carbons._getForwarded', e);
}
}; | CWE-20 | 0 |
isExpOperator: function(ch) {
return (ch === '-' || ch === '+' || this.isNumber(ch));
}, | CWE-74 | 1 |
k&&k(x)}}),k)};EditorUi.prototype.removeDatabaseItem=function(c,e,g,k){this.openDatabase(mxUtils.bind(this,function(m){k=k||"objects";Array.isArray(k)||(k=[k],c=[c]);m=m.transaction(k,"readwrite");m.oncomplete=e;m.onerror=g;for(var q=0;q<k.length;q++)m.objectStore(k[q]).delete(c[q])}),g)};EditorUi.prototype.getDatabaseItem=function(c,e,g,k){this.openDatabase(mxUtils.bind(this,function(m){try{k=k||"objects";var q=m.transaction([k],"readonly").objectStore(k).get(c);q.onsuccess=function(){e(q.result)};
q.onerror=g}catch(v){null!=g&&g(v)}}),g)};EditorUi.prototype.getDatabaseItems=function(c,e,g){this.openDatabase(mxUtils.bind(this,function(k){try{g=g||"objects";var m=k.transaction([g],"readonly").objectStore(g).openCursor(IDBKeyRange.lowerBound(0)),q=[];m.onsuccess=function(v){null==v.target.result?c(q):(q.push(v.target.result.value),v.target.result.continue())};m.onerror=e}catch(v){null!=e&&e(v)}}),e)};EditorUi.prototype.getDatabaseItemKeys=function(c,e,g){this.openDatabase(mxUtils.bind(this,function(k){try{g= | CWE-20 | 0 |
M.push(D);A.appendChild(D);var E=function(oa){Ba.style.display="none";fa.style.display="none";Z.style.left="30px";u(oa?-1:1);null==W&&(W=La);Z.scrollTop=0;Z.innerHTML="";S.spin(Z);var sa=function(ya,wa,ua){H=0;S.stop();La=ya;ua=ua||{};var xa=0,ha;for(ha in ua)xa+=ua[ha].length;if(wa)Z.innerHTML=wa;else if(0==ya.length&&0==xa)Z.innerHTML=mxUtils.htmlEntities(mxResources.get("noDiagrams",null,"No Diagrams Found"));else if(Z.innerHTML="",0<xa){Ba.style.display="";Z.style.left="160px";Ba.innerHTML="";
Na=0;Ca={"draw.io":ya};for(ha in ua)Ca[ha]=ua[ha];C()}else O(!0)};oa?q(J.value,sa):p(sa)};p&&(D=mxUtils.button(mxResources.get("Recent",null,"Recent"),function(){E()}),A.appendChild(D),M.push(D));if(q){D=document.createElement("span");D.style.marginLeft="10px";D.innerHTML=mxUtils.htmlEntities(mxResources.get("search")+":");A.appendChild(D);var J=document.createElement("input");J.style.marginRight="10px";J.style.marginLeft="10px";J.style.width="220px";mxEvent.addListener(J,"keypress",function(oa){13== | CWE-20 | 0 |
DotObject.prototype.copy = function (source, target, obj1, obj2, mods, merge) {
if (typeof mods === 'function' || Array.isArray(mods)) {
this.set(target,
_process(
// clone what is picked
JSON.parse(
JSON.stringify(
this.pick(source, obj1, false)
)
),
mods
), obj2, merge)
} else {
merge = mods
this.set(target, this.pick(source, obj1, false), obj2, merge)
}
return obj2
} | CWE-74 | 1 |
T[N],"cells"),this.updateCustomLinkAction(u,T[N],"excludeCells")}};Graph.prototype.updateCustomLinkAction=function(u,E,J){if(null!=E&&null!=E[J]){for(var T=[],N=0;N<E[J].length;N++)if("*"==E[J][N])T.push(E[J][N]);else{var Q=u[E[J][N]];null!=Q?""!=Q&&T.push(Q):T.push(E[J][N])}E[J]=T}};Graph.prototype.getCellsForAction=function(u,E){E=this.getCellsById(u.cells).concat(this.getCellsForTags(u.tags,null,E));if(null!=u.excludeCells){for(var J=[],T=0;T<E.length;T++)0>u.excludeCells.indexOf(E[T].id)&&J.push(E[T]); | CWE-20 | 0 |
ua.prototype.constraints=mxEllipse.prototype.constraints;Qa.prototype.constraints=mxEllipse.prototype.constraints;Ra.prototype.constraints=mxRectangleShape.prototype.constraints;Ta.prototype.constraints=mxRectangleShape.prototype.constraints;wa.prototype.getConstraints=function(c,l,x){c=[];var p=Math.min(l,x/2),v=Math.min(l-p,Math.max(0,parseFloat(mxUtils.getValue(this.style,"size",this.size)))*l);c.push(new mxConnectionConstraint(new mxPoint(0,.5),!1,null));c.push(new mxConnectionConstraint(new mxPoint(0,
0),!1,null,v,0));c.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(v+l-p),0));c.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,l-p,0));c.push(new mxConnectionConstraint(new mxPoint(1,.5),!1,null));c.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,l-p,x));c.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(v+l-p),x));c.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,v,x));return c};va.prototype.getConstraints=function(c,l,x){l=parseFloat(mxUtils.getValue(c, | CWE-20 | 0 |
S&&S(M)}}))}catch(L){null!=S&&S(L)}}),N,sa)}catch(Pa){null!=S&&S(Pa)}};Editor.crcTable=[];for(var D=0;256>D;D++)for(var t=D,F=0;8>F;F++)t=1==(t&1)?3988292384^t>>>1:t>>>1,Editor.crcTable[D]=t;Editor.updateCRC=function(u,J,N,W){for(var S=0;S<W;S++)u=Editor.crcTable[(u^J.charCodeAt(N+S))&255]^u>>>8;return u};Editor.crc32=function(u){for(var J=-1,N=0;N<u.length;N++)J=J>>>8^Editor.crcTable[(J^u.charCodeAt(N))&255];return(J^-1)>>>0};Editor.writeGraphModelToPng=function(u,J,N,W,S){function P(sa,Ba){var ta= | CWE-20 | 0 |
'binary/': function(left, right, context) {
return function(scope, locals, assign, inputs) {
var arg = left(scope, locals, assign, inputs) / right(scope, locals, assign, inputs);
return context ? {value: arg} : arg;
};
}, | CWE-74 | 1 |
return P.apply(this,arguments)};mxGraphView.prototype.createEnumerationValue=function(u){u=decodeURIComponent(mxUtils.getValue(u.style,"enumerateValue",""));""==u&&(u=++this.enumerationState);return'<div style="padding:2px;border:1px solid gray;background:yellow;border-radius:2px;">'+mxUtils.htmlEntities(u)+"</div>"};mxGraphView.prototype.redrawEnumerationState=function(u){var E="1"==mxUtils.getValue(u.style,"enumerate",0);E&&null==u.secondLabel?(u.secondLabel=new mxText("",new mxRectangle,mxConstants.ALIGN_LEFT,
mxConstants.ALIGN_BOTTOM),u.secondLabel.size=12,u.secondLabel.state=u,u.secondLabel.dialect=mxConstants.DIALECT_STRICTHTML,this.graph.cellRenderer.initializeLabel(u,u.secondLabel)):E||null==u.secondLabel||(u.secondLabel.destroy(),u.secondLabel=null);E=u.secondLabel;if(null!=E){var J=u.view.scale,T=this.createEnumerationValue(u);u=this.graph.model.isVertex(u.cell)?new mxRectangle(u.x+u.width-4*J,u.y+4*J,0,0):mxRectangle.fromPoint(u.view.getPoint(u));E.bounds.equals(u)&&E.value==T&&E.scale==J||(E.bounds=
u,E.value=T,E.scale=J,E.redraw())}};var K=mxGraphView.prototype.validateBackgroundPage;mxGraphView.prototype.validateBackgroundPage=function(){K.apply(this,arguments);if(mxClient.IS_GC&&null!=this.getDrawPane()){var u=this.getDrawPane().parentNode;!this.graph.mathEnabled||mxClient.NO_FO||null!=this.webKitForceRepaintNode&&null!=this.webKitForceRepaintNode.parentNode||"svg"!=this.graph.container.firstChild.nodeName?null==this.webKitForceRepaintNode||this.graph.mathEnabled&&("svg"==this.graph.container.firstChild.nodeName|| | CWE-20 | 0 |
return na}function B(){function pa(oa,na){var Ja=mxResources.get(oa);null==Ja&&(Ja=oa.substring(0,1).toUpperCase()+oa.substring(1));18<Ja.length&&(Ja=Ja.substring(0,18)+"…");return Ja+" ("+na.length+")"}function sa(oa,na,Ja){mxEvent.addListener(na,"click",function(){Ea!=na&&(Ea.style.backgroundColor="",Ea=na,Ea.style.backgroundColor=D,Z.scrollTop=0,Z.innerHTML="",H=0,Ma=Ja?Ba[oa][Ja]:Da[oa],W=null,M(!1))})}Ia&&(Ia=!1,mxEvent.addListener(Z,"scroll",function(oa){Z.scrollTop+Z.clientHeight>=Z.scrollHeight&& | CWE-20 | 0 |
ca.src="/images/icon-search.svg"};b.sidebar.hideTooltip();b.sidebar.currentElt=da;Da=!0;ca.src="/images/aui-wait.gif";ha.isExt?g(ha,pa,function(){A(mxResources.get("cantLoadPrev"));Da=!1;ca.src="/images/icon-search.svg"}):ia(ha.url,pa)}}function t(ha,da,ca){if(null!=E){for(var la=E.className.split(" "),ia=0;ia<la.length;ia++)if(-1<la[ia].indexOf("Active")){la.splice(ia,1);break}E.className=la.join(" ")}null!=ha?(E=ha,E.className+=" "+da,J=ca,za.className="geTempDlgCreateBtn"):(J=E=null,za.className=
"geTempDlgCreateBtn geTempDlgBtnDisabled")}function z(ha,da){if(null!=J){var ca=function(pa){qa.isExternal?g(qa,function(na){la(na,pa)},ia):qa.url?mxUtils.get(TEMPLATE_PATH+"/"+qa.url,mxUtils.bind(this,function(na){200<=na.getStatus()&&299>=na.getStatus()?la(na.getText(),pa):ia()})):la(b.emptyDiagramXml,pa)},la=function(pa,na){y||b.hideDialog(!0);e(pa,na,qa,da)},ia=function(){A(mxResources.get("cannotLoad"));ma()},ma=function(){J=qa;za.className="geTempDlgCreateBtn";da&&(Ga.className="geTempDlgOpenBtn")}, | CWE-20 | 0 |
this.spacing=0}function Ca(){mxArrowConnector.call(this);this.spacing=0}function Ra(){mxActor.call(this)}function ab(){mxRectangleShape.call(this)}function Ka(){mxActor.call(this)}function bb(){mxActor.call(this)}function Pa(){mxActor.call(this)}function Za(){mxActor.call(this)}function z(){mxActor.call(this)}function L(){mxActor.call(this)}function M(){mxActor.call(this)}function T(){mxActor.call(this)}function ca(){mxActor.call(this)}function ia(){mxActor.call(this)}function ma(){mxEllipse.call(this)} | CWE-20 | 0 |
F.setGraphEnabled;F.setGraphEnabled=function(){sa.apply(this,arguments);null!=this.tabContainer&&(ka.style.visibility=this.tabContainer.style.visibility,this.diagramContainer.style.bottom="hidden"!=this.tabContainer.style.visibility&&null==T?this.tabContainerHeight+"px":"0px")}}X.appendChild(S);X.appendChild(F.diagramContainer);K.appendChild(X);F.updateTabContainer();!EditorUi.windowed&&("1"==urlParams.sketch||1E3<=c)&&"1"!=urlParams.embedInline&&b(this,!0);null==T&&X.appendChild(F.tabContainer); | CWE-20 | 0 |
if(null!=P&&null!=P.originalSrc)if(!G)P={src:P.originalSrc};else if(G&&null!=this.themes&&"darkTheme"==this.defaultThemeName){var K=this.stylesheet,F=this.shapeForegroundColor,H=this.shapeBackgroundColor;this.stylesheet=this.getDefaultStylesheet();this.shapeBackgroundColor="#ffffff";this.shapeForegroundColor="#000000";P=d.createImageForPageLink(P.originalSrc);this.shapeBackgroundColor=H;this.shapeForegroundColor=F;this.stylesheet=K}return P};var x=this.clearDefaultStyle;this.clearDefaultStyle=function(){x.apply(this,
arguments)};this.isOffline()||"undefined"===typeof window.EditDataDialog||(EditDataDialog.placeholderHelpLink="https://www.diagrams.net/doc/faq/predefined-placeholders");if(/viewer\.diagrams\.net$/.test(window.location.hostname)||/embed\.diagrams\.net$/.test(window.location.hostname))this.editor.editBlankUrl="https://app.diagrams.net/";var y=d.editor.getEditBlankUrl;this.editor.getEditBlankUrl=function(D){D=null!=D?D:"";"1"==urlParams.dev&&(D+=(0<D.length?"&":"?")+"dev=1");return y.apply(this,arguments)}; | CWE-20 | 0 |
mxActor);Za.prototype.arrowWidth=.3;Za.prototype.arrowSize=.2;Za.prototype.redrawPath=function(c,l,x,p,v){var A=v*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",this.arrowWidth))));l=p*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));x=(v-A)/2;A=x+A;var B=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(c,[new mxPoint(0,x),new mxPoint(p-l,x),new mxPoint(p-l,0),new mxPoint(p,v/2),new mxPoint(p-
l,v),new mxPoint(p-l,A),new mxPoint(0,A)],this.isRounded,B,!0);c.end()};mxCellRenderer.registerShape("singleArrow",Za);mxUtils.extend(z,mxActor);z.prototype.redrawPath=function(c,l,x,p,v){var A=v*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",Za.prototype.arrowWidth))));l=p*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",Za.prototype.arrowSize))));x=(v-A)/2;A=x+A;var B=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/ | CWE-20 | 0 |
async function download () {
return downloadURL(req.body.url, !debug, req.id)
} | CWE-863 | 11 |
function arrayRemove(array, value) {
var index = array.indexOf(value);
if (index >= 0) {
array.splice(index, 1);
}
return index;
} | CWE-74 | 1 |
this.init=function(){function G(H){if(null!=H){var S=H.getAttribute("background");if(null==S||""==S||S==mxConstants.NONE)S=Editor.isDarkMode()?"transparent":"#ffffff";z.style.backgroundColor=S;(new mxCodec(H.ownerDocument)).decode(H,L.getModel());L.maxFitScale=1;L.fit(8);L.center()}return H}function N(H){null!=H&&(H=G(Editor.parseDiagramNode(H)));return H}mxEvent.addListener(F,"change",function(H){y=parseInt(F.value);N(K[y]);mxEvent.consume(H)});if("mxfile"==n.nodeName){var J=n.getElementsByTagName("diagram"); | CWE-20 | 0 |
null!=this.linkHint&&(this.linkHint.style.visibility="")};var Za=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){Za.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.graph.getSelectionModel().removeListener(this.changeHandler),this.changeHandler=null)}}();(function(){function b(c,l,x){mxShape.call(this);this.line=c;this.stroke=l;this.strokewidth=null!=x?x:1;this.updateBoundsFromLine()}function e(){mxSwimlane.call(this)}function k(){mxSwimlane.call(this)}function n(){mxCylinder.call(this)}function D(){mxCylinder.call(this)}function t(){mxActor.call(this)}function F(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function f(){mxCylinder.call(this)}function g(){mxCylinder.call(this)}function m(){mxShape.call(this)}function q(){mxShape.call(this)} | CWE-20 | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.